1. We have added a Gift Upgrades feature that allows you to gift an account upgrade to another member, just in time for the holiday season. You can see the gift option when going to the Account Upgrades screen, or on any user profile screen.
    Dismiss Notice

Help with modifiers **SOLVED**

Discussion in 'Mod Creation Help' started by kantorr, Mar 5, 2017.

  1. kantorr

    kantorr Chieftain

    Joined:
    Mar 1, 2017
    Messages:
    51
    I'm trying to do a basic modifier for a Suzerain bonus: +1 Science from Fishing Boats.
    I feel like this should be super simple, but I image the issue I'm calling out ImprovementType and YieldType from the same modifier...
    The game simply crashes, and I can't find any errors to reference in the logs.
    Spoiler :

    <Modifiers>
    <Row>
    <ModifierId>MINOR_CIV_XXX_UNIQUE_INFLUENCE_BONUS</ModifierId>
    <ModifierType>MODIFIER_ALL_PLAYERS_ATTACH_MODIFIER</ModifierType>
    <SubjectRequirementSetId>PLAYER_IS_SUZERAIN</SubjectRequirementSetId>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <ModifierType>MODIFIER_CITY_PLOT_YIELD_ADJUST_PLOT_YIELD</ModifierType>
    </Row>
    </Modifiers>
    <ModifierArguments>
    <Row>
    <ModifierId>MINOR_CIV_XXX_UNIQUE_INFLUENCE_BONUS</ModifierId>
    <Name>ModifierId</Name>
    <Value>MINOR_CIV_XXX_FISHING_BOATS_BONUS</Value>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <Name>ImprovementType</Name>
    <Value>IMPROVEMENT_FISHING_BOATS</Value>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <Name>YieldType</Name>
    <Value>YIELD_SCIENCE</Value>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <Name>Amount</Name>
    <Value>1</Value>
    </Row>
    </ModifierArguments>
     
  2. kantorr

    kantorr Chieftain

    Joined:
    Mar 1, 2017
    Messages:
    51
    For those who come here looking for the same solution, this code works:

    Spoiler :

    <Modifiers>
    <Row>
    <ModifierId>MINOR_CIV_XXX_UNIQUE_INFLUENCE_BONUS</ModifierId>
    <ModifierType>MODIFIER_ALL_PLAYERS_ATTACH_MODIFIER</ModifierType>
    <SubjectRequirementSetId>PLAYER_IS_SUZERAIN</SubjectRequirementSetId>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <ModifierType>MODIFIER_PLAYER_ADJUST_PLOT_YIELD</ModifierType>
    <SubjectRequirementSetId>IMPROVEMENT_IS_FISHING_BOATS</SubjectRequirementSetId>
    </Row>
    </Modifiers>
    <ModifierArguments>
    <Row>
    <ModifierId>MINOR_CIV_XXX_UNIQUE_INFLUENCE_BONUS</ModifierId>
    <Name>ModifierId</Name>
    <Value>MINOR_CIV_XXX_FISHING_BOATS_BONUS</Value>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <Name>YieldType</Name>
    <Value>YIELD_SCIENCE</Value>
    </Row>
    <Row>
    <ModifierId>MINOR_CIV_XXX_FISHING_BOATS_BONUS</ModifierId>
    <Name>Amount</Name>
    <Value>1</Value>
    </Row>
    </ModifierArguments>
    <RequirementSets>
    <Row>
    <RequirementSetId>IMPROVEMENT_IS_FISHING_BOATS</RequirementSetId>
    <RequirementSetType>REQUIREMENTSET_TEST_ALL</RequirementSetType>
    </Row>
    </RequirementSets>
    <RequirementSetRequirements>
    <Row>
    <RequirementSetId>IMPROVEMENT_IS_FISHING_BOATS</RequirementSetId>
    <RequirementId>REQUIRES_IMPROVEMENT_IS_FISHING_BOATS</RequirementId>
    </Row>
    </RequirementSetRequirements>
    <Requirements>
    <Row>
    <RequirementId>REQUIRES_IMPROVEMENT_IS_FISHING_BOATS</RequirementId>
    <RequirementType>REQUIREMENT_PLOT_IMPROVEMENT_TYPE_MATCHES</RequirementType>
    </Row>
    </Requirements>
    <RequirementArguments>
    <Row>
    <RequirementId>REQUIRES_IMPROVEMENT_IS_FISHING_BOATS</RequirementId>
    <Name>ImprovementType</Name>
    <Value>IMPROVEMENT_FISHING_BOATS</Value>
    </Row>
    </RequirementArguments>
     

Share This Page