public EntityStatic(EntityMobile actor) { Type = actor.Type; Direction = actor.Direction.Current; Flags = actor.Flags; }
public void MoveDelay(EntityMobile actor, ushort duration) { if (actor.IsMoving) { return; } actor.Timer.Start(duration, false); }
public EntityMobile(EntityMobile other) { this.Type = other.Type; this.Position = other.Position; this.Direction = other.Direction; this.Flags = other.Flags; this.Timer = other.Timer; }
public void MoveFacing(EntityMobile actor, ushort duration, Direction direction) { if (actor.IsMoving) { return; } actor.Position.Next = actor.Position.Current; actor.Direction.Next = direction; actor.Timer.Start(duration, false); }
public void MoveCancel(EntityMobile actor) { if (!actor.IsMoving) { return; } actor.Position.Next = actor.Position.Current; actor.Direction.Next = actor.Direction.Current; actor.Timer.Reset(); }
public void MoveDown(EntityMobile actor, ushort duration) { Move(actor, actor.Position.Current.Down, Direction.LEFT, duration); }
public void MoveRight(EntityMobile actor, ushort duration) { Move(actor, actor.Position.Current.Right, Direction.LEFT, duration); }