예제 #1
0
 public WeihuaGames.ClientClass.CombatPlayer FromProtobuf(com.kodgames.corgi.protocol.CombatPlayer protocol)
 {
     this.playerId = protocol.playerId;
     foreach (com.kodgames.corgi.protocol.CombatAvatarData data in protocol.combatAvatarDatas)
     {
         this.combatAvatarDatas.Add(new WeihuaGames.ClientClass.CombatAvatarData().FromProtobuf(data));
     }
     return(this);
 }
예제 #2
0
 public com.kodgames.corgi.protocol.CombatPlayer ToProtobuf()
 {
     com.kodgames.corgi.protocol.CombatPlayer player = new com.kodgames.corgi.protocol.CombatPlayer {
         playerId = this.playerId
     };
     foreach (WeihuaGames.ClientClass.CombatAvatarData data in this.combatAvatarDatas)
     {
         player.combatAvatarDatas.Add(data.ToProtobuf());
     }
     return(player);
 }