public override void Serialize(IDataWriter writer) { writer.WriteShort(((short)(m_houses.Count))); int housesIndex; for (housesIndex = 0; (housesIndex < m_houses.Count); housesIndex = (housesIndex + 1)) { HouseInformations objectToSend = m_houses[housesIndex]; writer.WriteUShort(((ushort)(objectToSend.TypeID))); objectToSend.Serialize(writer); } writer.WriteShort(((short)(m_actors.Count))); int actorsIndex; for (actorsIndex = 0; (actorsIndex < m_actors.Count); actorsIndex = (actorsIndex + 1)) { GameRolePlayActorInformations objectToSend = m_actors[actorsIndex]; writer.WriteUShort(((ushort)(objectToSend.TypeID))); objectToSend.Serialize(writer); } writer.WriteShort(((short)(m_interactiveElements.Count))); int interactiveElementsIndex; for (interactiveElementsIndex = 0; (interactiveElementsIndex < m_interactiveElements.Count); interactiveElementsIndex = (interactiveElementsIndex + 1)) { InteractiveElement objectToSend = m_interactiveElements[interactiveElementsIndex]; writer.WriteUShort(((ushort)(objectToSend.TypeID))); objectToSend.Serialize(writer); } writer.WriteShort(((short)(m_statedElements.Count))); int statedElementsIndex; for (statedElementsIndex = 0; (statedElementsIndex < m_statedElements.Count); statedElementsIndex = (statedElementsIndex + 1)) { StatedElement objectToSend = m_statedElements[statedElementsIndex]; objectToSend.Serialize(writer); } writer.WriteShort(((short)(m_obstacles.Count))); int obstaclesIndex; for (obstaclesIndex = 0; (obstaclesIndex < m_obstacles.Count); obstaclesIndex = (obstaclesIndex + 1)) { MapObstacle objectToSend = m_obstacles[obstaclesIndex]; objectToSend.Serialize(writer); } writer.WriteShort(((short)(m_fights.Count))); int fightsIndex; for (fightsIndex = 0; (fightsIndex < m_fights.Count); fightsIndex = (fightsIndex + 1)) { FightCommonInformations objectToSend = m_fights[fightsIndex]; objectToSend.Serialize(writer); } m_fightStartPositions.Serialize(writer); writer.WriteVarShort(m_subAreaId); writer.WriteInt(m_mapId); writer.WriteBoolean(m_hasAggressiveMonsters); }
public override void Serialize(IDataWriter writer) { writer.WriteShort((short)((int)this.interactiveElements.Length)); InteractiveElement[] interactiveElementArray = this.interactiveElements; for (int i = 0; i < (int)interactiveElementArray.Length; i++) { InteractiveElement interactiveElement = interactiveElementArray[i]; writer.WriteShort(interactiveElement.TypeId); interactiveElement.Serialize(writer); } }
public override void Serialize(ICustomDataOutput writer) { writer.WriteShort(((short)(m_interactiveElements.Count))); int interactiveElementsIndex; for (interactiveElementsIndex = 0; (interactiveElementsIndex < m_interactiveElements.Count); interactiveElementsIndex = (interactiveElementsIndex + 1)) { InteractiveElement objectToSend = m_interactiveElements[interactiveElementsIndex]; writer.WriteUShort(((ushort)(objectToSend.TypeID))); objectToSend.Serialize(writer); } }
public override void Serialize(IDataWriter writer) { writer.WriteVarShort((int)this.subAreaId); writer.WriteInt(this.mapId); writer.WriteShort((short)((int)this.houses.Length)); HouseInformations[] houseInformationsArray = this.houses; for (int i = 0; i < (int)houseInformationsArray.Length; i++) { HouseInformations houseInformation = houseInformationsArray[i]; writer.WriteShort(houseInformation.TypeId); houseInformation.Serialize(writer); } writer.WriteShort((short)((int)this.actors.Length)); GameRolePlayActorInformations[] gameRolePlayActorInformationsArray = this.actors; for (int j = 0; j < (int)gameRolePlayActorInformationsArray.Length; j++) { GameRolePlayActorInformations gameRolePlayActorInformation = gameRolePlayActorInformationsArray[j]; writer.WriteShort(gameRolePlayActorInformation.TypeId); gameRolePlayActorInformation.Serialize(writer); } writer.WriteShort((short)((int)this.interactiveElements.Length)); InteractiveElement[] interactiveElementArray = this.interactiveElements; for (int k = 0; k < (int)interactiveElementArray.Length; k++) { InteractiveElement interactiveElement = interactiveElementArray[k]; writer.WriteShort(interactiveElement.TypeId); interactiveElement.Serialize(writer); } writer.WriteShort((short)((int)this.statedElements.Length)); StatedElement[] statedElementArray = this.statedElements; for (int l = 0; l < (int)statedElementArray.Length; l++) { statedElementArray[l].Serialize(writer); } writer.WriteShort((short)((int)this.obstacles.Length)); MapObstacle[] mapObstacleArray = this.obstacles; for (int m = 0; m < (int)mapObstacleArray.Length; m++) { mapObstacleArray[m].Serialize(writer); } writer.WriteShort((short)((int)this.fights.Length)); FightCommonInformations[] fightCommonInformationsArray = this.fights; for (int n = 0; n < (int)fightCommonInformationsArray.Length; n++) { fightCommonInformationsArray[n].Serialize(writer); } writer.WriteBoolean(this.hasAggressiveMonsters); }
public override void Serialize(ICustomDataOutput writer) { m_interactiveElement.Serialize(writer); }
public override void Serialize(IDataWriter writer) { interactiveElement.Serialize(writer); }