Пример #1
0
        public AnimatedObject()
            : base()
        {
            this.body = new Body.Body();
            this.scale = 1f;
            this.Size = new Vector3(32, 32, 0);

            this.movementSpeed = 1.0f;

            this.updatePositionTimerMax = 5;
            this.updatePositionTimer = this.updatePositionTimerMax;
        }
Пример #2
0
        public AnimatedObject(SerializationInfo info, StreamingContext ctxt)
            : base(info, ctxt)
        {
            this.scale = (float)info.GetValue("scale", typeof(float));
            this.movementSpeed = (float)info.GetValue("movementSpeed", typeof(float));

            this.directionEnum = (DirectionEnum)info.GetValue("directionEnum", typeof(DirectionEnum));

            this.body = (Body.Body)info.GetValue("body", typeof(Body.Body));

            this.moveUp = (bool)info.GetValue("moveUp", typeof(bool));
            this.moveLeft = (bool)info.GetValue("moveLeft", typeof(bool));
            this.moveRight = (bool)info.GetValue("moveRight", typeof(bool));
            this.moveDown = (bool)info.GetValue("moveDown", typeof(bool));
        }
 public UpdateAnimatedObjectBodyMessage(int _Id, Body _Body)
 {
     this.MessageTime = NetTime.Now;
     this.Id = _Id;
     this.Body = _Body;
 }