public void MergeFrom(pb::CodedInputStream input)
                {
                    uint tag;

                    while ((tag = input.ReadTag()) != 0)
                    {
                        switch (tag)
                        {
                        default:
                            input.SkipLastField();
                            break;

                        case 10: {
                            TemplateId = input.ReadString();
                            break;
                        }

                        case 18: {
                            if (pokemonSettings_ == null)
                            {
                                pokemonSettings_ = new global::PokemonGoDesktop.API.Proto.PokemonSettings();
                            }
                            input.ReadMessage(pokemonSettings_);
                            break;
                        }

                        case 26: {
                            if (itemSettings_ == null)
                            {
                                itemSettings_ = new global::PokemonGoDesktop.API.Proto.ItemSettings();
                            }
                            input.ReadMessage(itemSettings_);
                            break;
                        }

                        case 34: {
                            if (moveSettings_ == null)
                            {
                                moveSettings_ = new global::PokemonGoDesktop.API.Proto.MoveSettings();
                            }
                            input.ReadMessage(moveSettings_);
                            break;
                        }

                        case 42: {
                            if (moveSequenceSettings_ == null)
                            {
                                moveSequenceSettings_ = new global::PokemonGoDesktop.API.Proto.MoveSequenceSettings();
                            }
                            input.ReadMessage(moveSequenceSettings_);
                            break;
                        }

                        case 66: {
                            if (typeEffective_ == null)
                            {
                                typeEffective_ = new global::PokemonGoDesktop.API.Proto.TypeEffectiveSettings();
                            }
                            input.ReadMessage(typeEffective_);
                            break;
                        }

                        case 82: {
                            if (badgeSettings_ == null)
                            {
                                badgeSettings_ = new global::PokemonGoDesktop.API.Proto.BadgeSettings();
                            }
                            input.ReadMessage(badgeSettings_);
                            break;
                        }

                        case 90: {
                            if (camera_ == null)
                            {
                                camera_ = new global::PokemonGoDesktop.API.Proto.CameraSettings();
                            }
                            input.ReadMessage(camera_);
                            break;
                        }

                        case 98: {
                            if (playerLevel_ == null)
                            {
                                playerLevel_ = new global::PokemonGoDesktop.API.Proto.PlayerLevelSettings();
                            }
                            input.ReadMessage(playerLevel_);
                            break;
                        }

                        case 106: {
                            if (gymLevel_ == null)
                            {
                                gymLevel_ = new global::PokemonGoDesktop.API.Proto.GymLevelSettings();
                            }
                            input.ReadMessage(gymLevel_);
                            break;
                        }

                        case 114: {
                            if (battleSettings_ == null)
                            {
                                battleSettings_ = new global::PokemonGoDesktop.API.Proto.GymBattleSettings();
                            }
                            input.ReadMessage(battleSettings_);
                            break;
                        }

                        case 122: {
                            if (encounterSettings_ == null)
                            {
                                encounterSettings_ = new global::PokemonGoDesktop.API.Proto.EncounterSettings();
                            }
                            input.ReadMessage(encounterSettings_);
                            break;
                        }

                        case 130: {
                            if (iapItemDisplay_ == null)
                            {
                                iapItemDisplay_ = new global::PokemonGoDesktop.API.Proto.IapItemDisplay();
                            }
                            input.ReadMessage(iapItemDisplay_);
                            break;
                        }

                        case 138: {
                            if (iapSettings_ == null)
                            {
                                iapSettings_ = new global::PokemonGoDesktop.API.Proto.IapSettings();
                            }
                            input.ReadMessage(iapSettings_);
                            break;
                        }

                        case 146: {
                            if (pokemonUpgrades_ == null)
                            {
                                pokemonUpgrades_ = new global::PokemonGoDesktop.API.Proto.PokemonUpgradeSettings();
                            }
                            input.ReadMessage(pokemonUpgrades_);
                            break;
                        }

                        case 154: {
                            if (equippedBadges_ == null)
                            {
                                equippedBadges_ = new global::PokemonGoDesktop.API.Proto.EquippedBadgeSettings();
                            }
                            input.ReadMessage(equippedBadges_);
                            break;
                        }
                        }
                    }
                }
 public void MergeFrom(ItemTemplate other)
 {
     if (other == null)
     {
         return;
     }
     if (other.TemplateId.Length != 0)
     {
         TemplateId = other.TemplateId;
     }
     if (other.pokemonSettings_ != null)
     {
         if (pokemonSettings_ == null)
         {
             pokemonSettings_ = new global::PokemonGoDesktop.API.Proto.PokemonSettings();
         }
         PokemonSettings.MergeFrom(other.PokemonSettings);
     }
     if (other.itemSettings_ != null)
     {
         if (itemSettings_ == null)
         {
             itemSettings_ = new global::PokemonGoDesktop.API.Proto.ItemSettings();
         }
         ItemSettings.MergeFrom(other.ItemSettings);
     }
     if (other.moveSettings_ != null)
     {
         if (moveSettings_ == null)
         {
             moveSettings_ = new global::PokemonGoDesktop.API.Proto.MoveSettings();
         }
         MoveSettings.MergeFrom(other.MoveSettings);
     }
     if (other.moveSequenceSettings_ != null)
     {
         if (moveSequenceSettings_ == null)
         {
             moveSequenceSettings_ = new global::PokemonGoDesktop.API.Proto.MoveSequenceSettings();
         }
         MoveSequenceSettings.MergeFrom(other.MoveSequenceSettings);
     }
     if (other.typeEffective_ != null)
     {
         if (typeEffective_ == null)
         {
             typeEffective_ = new global::PokemonGoDesktop.API.Proto.TypeEffectiveSettings();
         }
         TypeEffective.MergeFrom(other.TypeEffective);
     }
     if (other.badgeSettings_ != null)
     {
         if (badgeSettings_ == null)
         {
             badgeSettings_ = new global::PokemonGoDesktop.API.Proto.BadgeSettings();
         }
         BadgeSettings.MergeFrom(other.BadgeSettings);
     }
     if (other.camera_ != null)
     {
         if (camera_ == null)
         {
             camera_ = new global::PokemonGoDesktop.API.Proto.CameraSettings();
         }
         Camera.MergeFrom(other.Camera);
     }
     if (other.playerLevel_ != null)
     {
         if (playerLevel_ == null)
         {
             playerLevel_ = new global::PokemonGoDesktop.API.Proto.PlayerLevelSettings();
         }
         PlayerLevel.MergeFrom(other.PlayerLevel);
     }
     if (other.gymLevel_ != null)
     {
         if (gymLevel_ == null)
         {
             gymLevel_ = new global::PokemonGoDesktop.API.Proto.GymLevelSettings();
         }
         GymLevel.MergeFrom(other.GymLevel);
     }
     if (other.battleSettings_ != null)
     {
         if (battleSettings_ == null)
         {
             battleSettings_ = new global::PokemonGoDesktop.API.Proto.GymBattleSettings();
         }
         BattleSettings.MergeFrom(other.BattleSettings);
     }
     if (other.encounterSettings_ != null)
     {
         if (encounterSettings_ == null)
         {
             encounterSettings_ = new global::PokemonGoDesktop.API.Proto.EncounterSettings();
         }
         EncounterSettings.MergeFrom(other.EncounterSettings);
     }
     if (other.iapItemDisplay_ != null)
     {
         if (iapItemDisplay_ == null)
         {
             iapItemDisplay_ = new global::PokemonGoDesktop.API.Proto.IapItemDisplay();
         }
         IapItemDisplay.MergeFrom(other.IapItemDisplay);
     }
     if (other.iapSettings_ != null)
     {
         if (iapSettings_ == null)
         {
             iapSettings_ = new global::PokemonGoDesktop.API.Proto.IapSettings();
         }
         IapSettings.MergeFrom(other.IapSettings);
     }
     if (other.pokemonUpgrades_ != null)
     {
         if (pokemonUpgrades_ == null)
         {
             pokemonUpgrades_ = new global::PokemonGoDesktop.API.Proto.PokemonUpgradeSettings();
         }
         PokemonUpgrades.MergeFrom(other.PokemonUpgrades);
     }
     if (other.equippedBadges_ != null)
     {
         if (equippedBadges_ == null)
         {
             equippedBadges_ = new global::PokemonGoDesktop.API.Proto.EquippedBadgeSettings();
         }
         EquippedBadges.MergeFrom(other.EquippedBadges);
     }
 }