public override void Read(PacketReader r) { Time = r.ReadInt32(); SlotObject = (SlotObject)new SlotObject().Read(r); ItemUsePos = (Location)new Location().Read(r); UseType = r.ReadByte(); }
public override void Read(PacketReader r) { Time = r.ReadInt32(); Position = (Location)new Location().Read(r); SlotObject1 = (SlotObject)new SlotObject().Read(r); SlotObject2 = (SlotObject)new SlotObject().Read(r); }
public override void Read(PacketReader r) { Time = r.ReadInt32(); BulletId = r.ReadByte(); ContainerType = r.ReadInt16(); Position = (Location)new Location().Read(r); Angle = r.ReadSingle(); }
public override void Read(PacketReader r) { EffectType = (EffectType)r.ReadByte(); TargetId = r.ReadInt32(); PosA =(Location) new Location().Read(r); PosB = (Location) new Location().Read(r); Color = ARGB.Read(r); }
public override void Read(PacketReader r) { Location = (Location) new Location().Read(r); Radius = r.ReadSingle(); Damage = r.ReadUInt16(); Effects = (ConditionEffectIndex)r.ReadByte(); EffectDuration = r.ReadSingle(); OriginType = r.ReadInt16(); }
public override void Read(PacketReader r) { BulletId = r.ReadByte(); OwnerId = r.ReadInt32(); ContainerType = r.ReadInt32(); StartingLoc = (Location) new Location().Read(r); Angle = r.ReadSingle(); Damage = r.ReadInt16(); }
public override void Read(PacketReader r) { TickId = r.ReadInt32(); Time = r.ReadInt32(); NewPosition = (Location)new Location().Read(r); Records = new LocationRecord[r.ReadInt16()]; for (int i = 0; i < Records.Length; i++) Records[i] = (LocationRecord)new LocationRecord().Read(r); }
public override void Read(PacketReader r) { BulletId = r.ReadByte(); OwnerId = r.ReadInt32(); BulletType = r.ReadByte(); Location = (Location) new Location().Read(r); Angle = r.ReadSingle(); Damage = r.ReadInt16(); if (r.BaseStream.Position < r.BaseStream.Length) { NumShots = r.ReadByte(); AngleInc = r.ReadSingle(); } else { NumShots = 1; AngleInc = 0.0F; } }
public override void Read(PacketReader r) { Time = r.ReadInt32(); Position = (Location)new Location().Read(r); }
private float GetAngle(Location l1, Location l2) { float dX = l2.X - l1.X; float dY = l2.Y - l1.Y; return (float)Math.Atan2(dY, dX); }
public float DistanceTo(Location location) { return (float)Math.Sqrt(DistanceSquaredTo(location)); }
public float DistanceSquaredTo(Location location) { float dx = location.X - X; float dy = location.Y - Y; return dx * dx + dy * dy; }
public override void Read(PacketReader r) { ObjectId = r.ReadInt32(); Location = (Location) new Location().Read(r); }
public void Parse(NewTickPacket newTick) { foreach (Status status in newTick.Statuses) if (status.ObjectId == OwnerObjectId) foreach (StatData data in status.Data) { Pos = status.Position; Parse(data.Id, data.IntValue, data.StringValue); } }