public void DoRealTimeTask(List <Network.PowerHistory> powerList, int index) { GameState state = GameState.Get(); switch (this.m_power.Type) { case Network.PowerType.FULL_ENTITY: { Network.HistFullEntity power = (Network.HistFullEntity) this.m_power; state.OnRealTimeFullEntity(power); break; } case Network.PowerType.SHOW_ENTITY: { Network.HistShowEntity showEntity = (Network.HistShowEntity) this.m_power; state.OnRealTimeShowEntity(showEntity); break; } case Network.PowerType.TAG_CHANGE: { Network.HistTagChange change = (Network.HistTagChange) this.m_power; state.OnRealTimeTagChange(change); break; } case Network.PowerType.CREATE_GAME: { Network.HistCreateGame createGame = (Network.HistCreateGame) this.m_power; state.OnRealTimeCreateGame(powerList, index, createGame); break; } } }
private void SerializeCreateGame(Network.HistCreateGame cg, BinaryWriter w) { SerializeEntity(cg.Game, w); w.Write(cg.Players.Count); foreach (var p in cg.Players) { SerializeEntity(p.Player, w); w.Write(p.ID); w.Write(IsLocal(p)); } }
public ZoneChange CreateZoneChangeFromCreateGame(Network.HistCreateGame createGame) { object[] objArray1 = new object[] { createGame }; return(base.method_14 <ZoneChange>("CreateZoneChangeFromCreateGame", objArray1)); }