public void Dispose() { GameClient.SendToSpacemap(Spacemap, netty.commands.old_client.LegacyModule.write("0|q|" + Hash)); Spacemap.RemoveObject(this); Disposed = true; Respawn(); }
public virtual void Dispose() { //todo: fix //GameClient.SendToSpacemap(Spacemap, netty.commands.new_client.DisposeBoxCommand.write(Hash, true)); //GameClient.SendToSpacemap(Spacemap, netty.commands.old_client.LegacyModule.write("0|2|" + Hash)); Spacemap.RemoveObject(this); Disposed = true; }
public void Explode() { if (PlacedTime.AddSeconds(1) > DateTime.Now) { return; } GameClient.SendToSpacemap(Spacemap, netty.commands.old_client.LegacyModule.write("0|n|MIN|" + Hash)); GameClient.SendToSpacemap(Spacemap, netty.commands.new_client.LegacyModule.write("0|n|MIN|" + Hash)); Effect(); Spacemap.RemoveObject(this); }
public virtual void Dispose() { try { GameClient.SendToSpacemap(Spacemap, netty.commands.new_client.DisposeBoxCommand.write(Hash, true)); GameClient.SendToSpacemap(Spacemap, netty.commands.old_client.LegacyModule.write("0|2|" + Hash)); Spacemap.RemoveObject(this); Disposed = true; } catch (Exception e) { Console.WriteLine(e); Console.WriteLine(e.Message); Console.WriteLine(e.StackTrace); } }
public void CreateBattleStation() { Building = false; var battleStation = new ClanBattleStation(Spacemap.GetNextObjectId(), AssignedBattleStationId, Name, Faction, new Vector(Position.X, Position.Y), Spacemap, Builder, EquippedModules); Spacemap.RemoveObject(this); GameClient.SendToSpacemap(Spacemap, netty.commands.old_client.AssetRemoveCommand.write(new netty.commands.old_client.AssetTypeModule((short)Type), Id)); foreach (var module in EquippedModules.Values) { module.BattleStation = battleStation; if (module.SlotId == 0 || module.SlotId == 1) { continue; } module.Position = BattleStationModule.GetPos(battleStation.Position, module.SlotId); Spacemap.Objects[module.Id] = module; } Spacemap.AddObject(battleStation); }
public void Detonate() { GameClient.SendToSpacemap(Spacemap, netty.commands.old_client.LegacyModule.write("0|n|FWI|" + Hash)); GameClient.SendToSpacemap(Spacemap, netty.commands.new_client.LegacyModule.write("0|n|FWI|" + Hash)); Spacemap.RemoveObject(this); }