Exemplo n.º 1
0
        public int GetMoralValue(GovernmentInfo.GovernmentType gt, MoralEvent me, int originalValue)
        {
            Dictionary <MoralEvent, int> dictionary;

            if (this._factionSpecificMoral.TryGetValue(gt, out dictionary))
            {
                int num = 0;
                if (this._factionSpecificMoral[gt].TryGetValue(me, out num))
                {
                    return(num);
                }
            }
            return(originalValue);
        }
Exemplo n.º 2
0
        public int GetMoralTotal(
            GameDatabase gamedb,
            GovernmentInfo.GovernmentType gt,
            MoralEvent me,
            int player,
            int moral)
        {
            GovEffectCollection effectCollection;

            if (this.DiplomaticEffects.TryGetValue(gt, out effectCollection))
            {
                return(effectCollection.MoralEffects.GetResultingMoral(gamedb, me, player, moral));
            }
            return(moral);
        }