public MinimapPingAction(int sequence, int frame, IPlayer player, IMapPosition mapPosition) : base(sequence, frame, player) { this.MapPosition = mapPosition; ActionType = ActionType.MinimapPing; }
private BuildAction ParseBuildAction() { IMapPosition mapPosition = ParseMapPosition(); OrderType orderType = (OrderType)_input.ReadByte(); ObjectType objectType = (ObjectType)_input.ReadShort(); return(new BuildAction(sequence, frame, player, orderType, mapPosition, objectType)); }
public bool Equals(IMapPosition b) { if (!(b is Vertex)) { return(false); } return(Equals((Vertex)b)); }
public float Cost(IMapPosition parent) { var Other = (MapPosition)parent; int dx = (X - Other.X); int dy = (Y - Other.Y); int dz = (Z - Other.Z); return((float)Math.Sqrt(dx * dx + dy * dy + dz * dz)); }
public float Cost(IMapPosition position) { if (position == null) { return(0); } return(Heuristic(this, (Vertex)position)); }
private TargetAction ParseTargetAction() { IMapPosition position = ParseMapPosition(); int objectId = _input.ReadUnsignedShort(); OrderType orderType = (OrderType)_input.ReadByte(); ObjectType objectType = (ObjectType)_input.ReadShort(); QueueType queueType = (QueueType)_input.ReadByte(); return(new TargetAction(sequence, frame, player, position, objectId, objectType, orderType, queueType)); }
private RightClickAction ParseRightClickAction() { IMapPosition mapPosition = ParseMapPosition(); short memoryId = _input.ReadShort(); ObjectType objectType = (ObjectType)_input.ReadShort(); QueueType queueType = (QueueType)_input.ReadByte(); return(new RightClickAction(sequence, frame, player, mapPosition, memoryId, objectType, queueType)); }
public bool Equals(IMapPosition b) { if (!(b is MapPosition)) { return(false); } var Comp = (MapPosition)b; return(Comp.X == X && Comp.Y == Y && Comp.Z == Z); }
public BuildAction(int sequence, int frame, IPlayer player, OrderType orderType, IMapPosition mapPosition, ObjectType objectType) : base(sequence, frame, player) { this.OrderType = orderType; this.MapPosition = mapPosition; this.ObjectType = objectType; ActionType = ActionType.Build; }
public RightClickAction(int sequence, int frame, IPlayer player, IMapPosition mapPosition, short memoryId, ObjectType objectType, QueueType queueType) : base(sequence, frame, player) { this.MapPosition = mapPosition; this.MemoryIdentifier = memoryId; this.ObjectType = objectType; this.QueueType = queueType; ActionType = ActionType.RightClick; }
public TargetAction(int sequence, int frame, IPlayer player, IMapPosition mapPosition, int objectId, ObjectType objectType, OrderType orderType, QueueType queueType) : base(sequence, frame, player) { this.MapPosition = mapPosition; this.ObjectIdentifier = objectId; this.ObjectType = objectType; this.OrderType = orderType; this.QueueType = queueType; ActionType = ActionType.Target; }
public LiftAction(int sequence, int frame, IPlayer player, IMapPosition mapPosition) : base(sequence, frame, player) { MapPosition = mapPosition; ActionType = ActionType.Lift; }
private MinimapPingAction ParseMinimapPingAction() { IMapPosition mapPosition = ParseMapPosition(); return(new MinimapPingAction(sequence, frame, player, mapPosition)); }
private LiftAction ParseLiftAction() { IMapPosition position = ParseMapPosition(); return(new LiftAction(sequence, frame, player, position)); }