コード例 #1
0
        public override void Serialize(IDataWriter writer)
        {
            writer.WriteShort(((short)(m_monsters.Count)));
            int monstersIndex;

            for (monstersIndex = 0; (monstersIndex < m_monsters.Count); monstersIndex = (monstersIndex + 1))
            {
                MonsterInGroupLightInformations objectToSend = m_monsters[monstersIndex];
                objectToSend.Serialize(writer);
            }
            writer.WriteInt(m_playerCount);
        }
コード例 #2
0
        public override void Deserialize(IDataReader reader)
        {
            int monstersCount = reader.ReadUShort();
            int monstersIndex;

            m_monsters = new System.Collections.Generic.List <MonsterInGroupLightInformations>();
            for (monstersIndex = 0; (monstersIndex < monstersCount); monstersIndex = (monstersIndex + 1))
            {
                MonsterInGroupLightInformations objectToAdd = new MonsterInGroupLightInformations();
                objectToAdd.Deserialize(reader);
                m_monsters.Add(objectToAdd);
            }
            m_playerCount = reader.ReadInt();
        }
コード例 #3
0
        public override void Deserialize(IDataReader reader)
        {
            m_mainCreatureLightInfos = new MonsterInGroupLightInformations();
            m_mainCreatureLightInfos.Deserialize(reader);
            int underlingsCount = reader.ReadUShort();
            int underlingsIndex;

            m_underlings = new System.Collections.Generic.List <MonsterInGroupInformations>();
            for (underlingsIndex = 0; (underlingsIndex < underlingsCount); underlingsIndex = (underlingsIndex + 1))
            {
                MonsterInGroupInformations objectToAdd = new MonsterInGroupInformations();
                objectToAdd.Deserialize(reader);
                m_underlings.Add(objectToAdd);
            }
        }
コード例 #4
0
 public GroupMonsterStaticInformations(MonsterInGroupLightInformations mainCreatureLightInfos, List <MonsterInGroupInformations> underlings)
 {
     m_mainCreatureLightInfos = mainCreatureLightInfos;
     m_underlings             = underlings;
 }