Ejemplo n.º 1
0
        public override int GetHashCode()
        {
            int hash = 1;

            if (typeCase_ == TypeOneofCase.DoEncounter)
            {
                hash ^= DoEncounter.GetHashCode();
            }
            if (typeCase_ == TypeOneofCase.LootOutposts)
            {
                hash ^= LootOutposts.GetHashCode();
            }
            if (typeCase_ == TypeOneofCase.WinTraces)
            {
                hash ^= WinTraces.GetHashCode();
            }
            if (typeCase_ == TypeOneofCase.CollectPotionIngredients)
            {
                hash ^= CollectPotionIngredients.GetHashCode();
            }
            if (typeCase_ == TypeOneofCase.BrewPotions)
            {
                hash ^= BrewPotions.GetHashCode();
            }
            if (typeCase_ == TypeOneofCase.WalkDistance)
            {
                hash ^= WalkDistance.GetHashCode();
            }
            if (typeCase_ == TypeOneofCase.PlayFortressChallenges)
            {
                hash ^= PlayFortressChallenges.GetHashCode();
            }
            hash ^= (int)typeCase_;
            if (_unknownFields != null)
            {
                hash ^= _unknownFields.GetHashCode();
            }
            return(hash);
        }
Ejemplo n.º 2
0
        public void MergeFrom(HookQuestTask other)
        {
            if (other == null)
            {
                return;
            }
            switch (other.TypeCase)
            {
            case TypeOneofCase.DoEncounter:
                if (DoEncounter == null)
                {
                    DoEncounter = new global::WUProtos.Data.DoEncounterHookQuestTask();
                }
                DoEncounter.MergeFrom(other.DoEncounter);
                break;

            case TypeOneofCase.LootOutposts:
                if (LootOutposts == null)
                {
                    LootOutposts = new global::WUProtos.Data.Loot.LootOutpostsQuestTask();
                }
                LootOutposts.MergeFrom(other.LootOutposts);
                break;

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

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

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

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

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

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