public void MergeFrom(ActiveBuffSource other)
        {
            if (other == null)
            {
                return;
            }
            switch (other.TypeCase)
            {
            case TypeOneofCase.VaultItem:
                if (VaultItem == null)
                {
                    VaultItem = new global::WUProtos.Data.VaultItemActiveBuffSource();
                }
                VaultItem.MergeFrom(other.VaultItem);
                break;

            case TypeOneofCase.Profession:
                if (Profession == null)
                {
                    Profession = new global::WUProtos.Data.Profession.ProfessionActiveBuffSource();
                }
                Profession.MergeFrom(other.Profession);
                break;

            case TypeOneofCase.MapAbility:
                if (MapAbility == null)
                {
                    MapAbility = new global::WUProtos.Map.MapAbilityActiveBuffSource();
                }
                MapAbility.MergeFrom(other.MapAbility);
                break;
            }

            _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
        }
示例#2
0
        public void MergeFrom(BuffDuration other)
        {
            if (other == null)
            {
                return;
            }
            switch (other.TypeCase)
            {
            case TypeOneofCase.Time:
                if (Time == null)
                {
                    Time = new global::WUProtos.Data.Buff.TimeBuffDuration();
                }
                Time.MergeFrom(other.Time);
                break;

            case TypeOneofCase.Charges:
                if (Charges == null)
                {
                    Charges = new global::WUProtos.Data.ChargesBuffDuration();
                }
                Charges.MergeFrom(other.Charges);
                break;

            case TypeOneofCase.Profession:
                if (Profession == null)
                {
                    Profession = new global::WUProtos.Data.Profession.ProfessionBuffDuration();
                }
                Profession.MergeFrom(other.Profession);
                break;

            case TypeOneofCase.Permanent:
                if (Permanent == null)
                {
                    Permanent = new global::WUProtos.Data.Buff.PermanentBuffDuration();
                }
                Permanent.MergeFrom(other.Permanent);
                break;

            case TypeOneofCase.Instant:
                if (Instant == null)
                {
                    Instant = new global::WUProtos.Data.Buff.InstantBuffDuration();
                }
                Instant.MergeFrom(other.Instant);
                break;

            case TypeOneofCase.Challenge:
                if (Challenge == null)
                {
                    Challenge = new global::WUProtos.Data.Challenge.ChallengeBuffDuration();
                }
                Challenge.MergeFrom(other.Challenge);
                break;
            }

            _unknownFields = pb::UnknownFieldSet.MergeFrom(_unknownFields, other._unknownFields);
        }