Beispiel #1
0
 public void MergeFrom(CatchPokemonResponse other)
 {
     if (other == null)
     {
         return;
     }
     if (other.Status != 0)
     {
         Status = other.Status;
     }
     if (other.MissPercent != 0D)
     {
         MissPercent = other.MissPercent;
     }
     if (other.CapturedPokemonId != 0UL)
     {
         CapturedPokemonId = other.CapturedPokemonId;
     }
     if (other.captureAward_ != null)
     {
         if (captureAward_ == null)
         {
             captureAward_ = new global::POGOProtos.Data.Capture.CaptureAward();
         }
         CaptureAward.MergeFrom(other.CaptureAward);
     }
     if (other.CaptureReason != 0)
     {
         CaptureReason = other.CaptureReason;
     }
 }
Beispiel #2
0
        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;

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

                case 8: {
                    status_ = (global::POGOProtos.Networking.Responses.CatchPokemonResponse.Types.CatchStatus)input.ReadEnum();
                    break;
                }

                case 17: {
                    MissPercent = input.ReadDouble();
                    break;
                }

                case 25: {
                    CapturedPokemonId = input.ReadFixed64();
                    break;
                }

                case 34: {
                    if (captureAward_ == null)
                    {
                        captureAward_ = new global::POGOProtos.Data.Capture.CaptureAward();
                    }
                    input.ReadMessage(captureAward_);
                    break;
                }

                case 40: {
                    captureReason_ = (global::POGOProtos.Networking.Responses.CatchPokemonResponse.Types.CaptureReason)input.ReadEnum();
                    break;
                }

                case 48: {
                    DisplayPokedexId = input.ReadInt32();
                    break;
                }

                case 56: {
                    ThrowsRemaining = input.ReadInt32();
                    break;
                }
                }
            }
        }