Esempio n. 1
0
 public void MergeFrom(User other)
 {
     if (other == null)
     {
         return;
     }
     if (other.UserId.Length != 0)
     {
         UserId = other.UserId;
     }
     if (other.transform_ != null)
     {
         if (transform_ == null)
         {
             Transform = new global::World.Transform_();
         }
         Transform.MergeFrom(other.Transform);
     }
     if (other.rotation_ != null)
     {
         if (rotation_ == null)
         {
             Rotation = new global::World.Rotation_();
         }
         Rotation.MergeFrom(other.Rotation);
     }
     _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
 }
Esempio n. 2
0
        public void MergeFrom(pb::CodedInputStream input)
        {
            uint tag;

            while ((tag = input.ReadTag()) != 0)
            {
                switch (tag)
                {
                default:
                    _unknownFields = pb::UnknownFieldSet.MergeFieldFrom(_unknownFields, input);
                    break;

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

                case 18: {
                    if (transform_ == null)
                    {
                        Transform = new global::World.Transform_();
                    }
                    input.ReadMessage(Transform);
                    break;
                }

                case 26: {
                    if (rotation_ == null)
                    {
                        Rotation = new global::World.Rotation_();
                    }
                    input.ReadMessage(Rotation);
                    break;
                }
                }
            }
        }