Exemplo n.º 1
0
        private void Overextension(SettlementInfo settlement, ref ExplainedNumber explainedNumber)
        {
            if (settlement.CurrentFaction.StringId == settlement.OriginalFaction.StringId)
            {
                return;
            }

            if (ModOptions.OptionsData.EmpireLoyaltyMechanics)
            {
                if (settlement.OriginalOwnerIsOfImperialCulture() && settlement.OwnerIsOfImperialCulture())
                {
                    return;
                }
            }

            int townsAboveInitialStart = RevolutionBehaviour.GetFactionInformation(settlement.CurrentFaction).TownsAboveInitial();

            explainedNumber.Add(-townsAboveInitialStart * OverExtensionMultiplier, GameTexts.FindText("str_loyalty_overextension"));
        }
Exemplo n.º 2
0
        private void BaseLoyalty(SettlementInfo info, ref ExplainedNumber explainedNumber)
        {
            if (ModOptions.OptionsData.EmpireLoyaltyMechanics)
            {
                if (info.OriginalOwnerIsOfImperialCulture())
                {
                    if (info.OwnerIsOfImperialCulture())
                    {
                        explainedNumber.Add(10, GameTexts.FindText("str_loyalty_imperial"));
                    }
                    else
                    {
                        explainedNumber.Add(-5, GameTexts.FindText("str_loyalty_foreignRule"));
                    }
                }
                else
                {
                    if (info.OwnerIsOfImperialCulture())
                    {
                        explainedNumber.Add(-5, GameTexts.FindText("str_loyalty_imperialAvers"));
                    }

                    if (info.OriginalFaction.StringId != info.CurrentFaction.StringId)
                    {
                        explainedNumber.Add(-5, GameTexts.FindText("str_loyalty_foreignRule"));
                    }
                }
            }
            else
            {
                if (info.OriginalFaction.StringId != info.CurrentFaction.StringId)
                {
                    explainedNumber.Add(-5, GameTexts.FindText("str_loyalty_foreignRule"));
                }
            }
        }