Not working......again....

Discussion in 'Civ5 - Creation & Customization' started by Scotch0101, Sep 15, 2014.

  1. Scotch0101

    Scotch0101 Centurion

    Joined:
    Jun 1, 2014
    Messages:
    138
    Location:
    A cool place
    As usual I've into another problem wth my mod. As I've solved the unit art problems (thank you LeeS!!!)
    Now I can't update policies. Out of every problem I could have thought of, I never thought I would have problems with UPDATING!!!!.......so simple......

    Here's the code:
    Code:
    <GameData>
                        <Policies>
                                 <Update>
                                 <Where type="POLICY_CITIZENSHIP"/>
                                 <Set>
                                           <Description>Adaptive Tactics</Description>
                                           <Help>+50% XP from combat</Help>
                                           <ExpModifier>50</ExpModifier>
                                 </Set>
    </Update>
                        </Policies>
                </GameData>
    Thanks in advance.
     
  2. bane_

    bane_ Howardianism High-Priest

    Joined:
    Nov 27, 2013
    Messages:
    1,559
    Now you offend me. :lol:


    I believe you can't have more than one <Set> child under only a single Update. But... you know, see above.
    Have you tried individualize the Updates tags?
     
  3. Scotch0101

    Scotch0101 Centurion

    Joined:
    Jun 1, 2014
    Messages:
    138
    Location:
    A cool place
    Not sure what you mean by 'individualize update tags'. This code I used here, I used to update units, civs, techs, and buildings. I got it from here.
     
  4. bane_

    bane_ Howardianism High-Priest

    Joined:
    Nov 27, 2013
    Messages:
    1,559
    Well, if the code comes from LeeS, ignore what I've said. :p
    Sorry I can't help you. :(

    I'm not at home right now, but I would take a look at the XML Tables from the game and see if there is no typo. Other than that, check the database.log (log is your friend!).
     
  5. LeeS

    LeeS Imperator

    Joined:
    Jul 23, 2013
    Messages:
    7,241
    Location:
    Illinois, USA
  6. Machiavelli24

    Machiavelli24 Mod creator

    Joined:
    May 9, 2012
    Messages:
    818
    LeeS already pointed out the thing that is causing the problem but there are a couple other things to note.

    1) Enable logging and check your logs. It will help you isolate the cause of issues.
    2) You're using help and description incorrectly, there is another layer of indirection involved. Your help should be a "variable" (TXT_KEY_POLICY_CITIZENSHIP) and in the English language table (there are tables for all the various languages Civ supports) you need to add/edit the entry for TXT_KEY_POLICY_CITIZENSHIP to be "Adaptive Tactics".
     
  7. Scotch0101

    Scotch0101 Centurion

    Joined:
    Jun 1, 2014
    Messages:
    138
    Location:
    A cool place
    Thanks guys! I typically don't use the TXT_KEY stuff, just cause I can.....but I guess it would be better to use it. I have logging turned on I just forget to check it. Thanks again! :sheep:
     
  8. PawelS

    PawelS Ancient Druid

    Joined:
    Dec 11, 2003
    Messages:
    2,803
    Location:
    Poland
    I think it's the Type capitalization as LeeS pointed out that causes your code to fail. Entering text directly into the database instead of text keys should work, although it produces errors in the log files. Multiple tags within <Set> are OK. Also note that the update you have made does not remove the existing effects of the policy, so it will both give +50% XP and the things it does normally - a free worker and faster improvement construction (unless you changed it elsewhere).
     
  9. Scotch0101

    Scotch0101 Centurion

    Joined:
    Jun 1, 2014
    Messages:
    138
    Location:
    A cool place
    I am planning to remove the worker part later, I just wanted to get it to work for now. I will test it later because I am sick and my mom doesn't let me use my computer when I'm sick.....but yet she let's me use my tablet :confused:.....anyway, thanks guys!
     

Share This Page