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

Reverting animal XP farm for solo play (2.8 -> 2.7)

Discussion in 'Civ4Col - We The People' started by Aerials, Jul 26, 2020.

  1. Aerials

    Aerials Chieftain

    Joined:
    Jul 26, 2020
    Messages:
    6
    Gender:
    Male
    Hi Guys, i love the improvements added with 2.8 but i really hate the removal of XP from animals on land and sea.
    i have been playing colonization since 1994 and cant believe how much better you guys made the mod than either of the official games. i have played WTP for about 400 hours (100% against AI only) and always loved farming animals on scouts for XP etc. i have tried to edit the files myself to remove the XP cap but cant get it to work (no animals spawn or XP still doesnt get earned, and i have 15 errors when launching the game)

    the removal of XP from animals kills my enjoyment so much that i have reverted to 2.7 even though i love changes introduced in 2.8.
    is it possible to add a toggle for animal XP farming at the game start menu or can someone on the forums help me to change my own game files?

    Thanks a lot
     
  2. devolution

    devolution Prince

    Joined:
    Oct 7, 2016
    Messages:
    385
    Gender:
    Male
    Location:
    Stavanger, Norway
    For 2.8 You can revert to the old behavior (i.e. no XP cap) by modifying the ANIMAL_MAX_XP_VALUE value (which is 2 by default) in Assets/XML/GlobalDefinesAlt.xml. Just set it to a very high number.
    Be warned: the AI is not capable of XP farming, so you will likely give yourself a significant advantage.
     
  3. Aerials

    Aerials Chieftain

    Joined:
    Jul 26, 2020
    Messages:
    6
    Gender:
    Male
    I initially tried that (set to 200) but animals still awarded 0 XP when killed


    edit: tried again with a fresh install of col and fresh install of mod, edited the XML to have xp cap set to 200. No wild animals will spawn on any map
    edit2: i get the following python errors 6 times when starting the game too (seems to be related to files in C:\Users\xxxx\Documents\My Games\Civilization IV Colonization - doesnt occur when folder is deleted)
     

    Attached Files:

    Last edited: Jul 26, 2020
  4. devolution

    devolution Prince

    Joined:
    Oct 7, 2016
    Messages:
    385
    Gender:
    Male
    Location:
    Stavanger, Norway
    Did you clear the cache (press and hold the shift key when launching the game) ?
     
  5. devolution

    devolution Prince

    Joined:
    Oct 7, 2016
    Messages:
    385
    Gender:
    Male
    Location:
    Stavanger, Norway
    If no wild animals are spawning at all, then that is a completely separate issue.
     
  6. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    These Python Errors are related to the Player Preferences (of Maps) stored in the Player Profile.
    They can only happen if you do not start WTP directly by shortcut but first load the base game (Vanilla) and then load the mod.

    Basically WTP has MapScripts with Settings have settings that Vanilla does not know.
    Those Maps and their Settings (for the Maps) are stored in your Player Preferences in the Player Profile.
    Once you start the game with Vanilla first, Vanilla tries to load the the Player Profile and stumbles because it does not find those Maps and those Settings.

    Edit:
    By deleting the folder you mentioned you basically also delete the stored Player Profile.

    These Python Errors are generally totally harmless though.
    Simply click them away and ignore them.
     
    Last edited: Jul 26, 2020
  7. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    Changing GlobalDefines always needs a new game to be started.
    Reinstallation or anything like that will not help if you still load an existing save game.
     
    devolution likes this.
  8. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    Well, AI does of course get XP from animals when it kills them, but of course it does not "farm XP from animals" purposely - like a Human Player might do.
    So it generally uses the same feature logic but simply less efficient.

    Generally however AI is not capable of "exploiting" any strategy on purpose.
    • AI does not use "Scout Rush" either.
    • AI does not use "Bell Rush" either.
    • AI does not use "Slave Rush" either.
    • AI does not declare "Wars on Natives to do XP farming" either.
    • AI does not "Abandon Cities" so it does not leave them to War enemies when it retreats either
    • ....
    All of that stuff can be considered an exploit - if you just think in terms "does AI use it as efficiently as a Human depending on the current game situation".
    Thus argumenting that things are exploits because AI can not use it purposely alone is a weak argument.

    More important is, if 1 single strategy is always completely overpowered - independent of the current game situation.
    --> Completely devaluing other strategies and destroying game balance.
    (Which in this case was not true. It is not overpowered compared to other strategies.)

    But in this case we also discussed other aspects like "immersion" if I remembered correctly.
    (It is strange that a Scout gets an "Elite Super Soldier" just from Hunting Wild Animals.)

    And as devolution said:
    There is a setting that can be used to change it to your personal preference. :thumbsup:

    Summary:
    For me personally this is less a question of "removing an exploit" than a questions of "immersion". Thus the change was completely ok for me.
    In fact in my games I hardly notice the difference - simply because I was never excessively trying to use "Wild Animal XP farming" myself.

    Edit:
    Of course we also need to continue to improve AI.
    It is currently no match to Human Players when it comes down to "using gameplay strategies situationally and efficiently".
     
    Last edited: Jul 26, 2020
  9. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    @devolution

    I checked the code and current balancing in GlobalDefinesAlt.xml and I think we have a small issue.
    (At the moment only possible for the combination "Indentured Servant" having a "Military Profession".)

    It is related to the "removing the XP farming from Runaways".

    I am concerned about this part:

    Code:
        if (getUnitInfo().LbD_canEscape())
           iMaxValue = std::min(iMaxValue, GC.getDefineINT("ESCAPE_MAX_XP_VALUE"));
    
    Code:
    <Define>
         <DefineName>ESCAPE_MAX_XP_VALUE</DefineName>
        <iDefineIntVal>0</iDefineIntVal>
    </Define>
    

    If I read the code correctly the Winner never gets XP from a Unit that is generally capable of "using LbD Escaping".
    (It does not consider the actual Profession.)

    But Indentured Servants can do both: run away and also use Military Professions.
    (In the current balancing they are the only Unit where this combination exists.)

    So for example:
    One of your Combat Units wins a battle against an Indentured Servant in a Military Profession (e.g. Dragoon),
    it does not get any XP, simply because the Indentured Servant is capable of using "LbD Escape" (when working in a City).

    How to fix it most easily:
    (Causing Indentured Servants to not run away anymore - which is ok for me.)

    Code:
    <bLbDCanEscape>0</bLbDCanEscape>
    
    Reason why this fix works (for current balancing):

    Currently other Units capable of using "LbD Escape" (African Slaves, Native Slaves and Petty Criminals) are not allowed to use Military Professions.
    (The issue could really only occur for Indentured Servants.)

    Technically maybe better solutions (in DLL instead of changing XML balancing):
    (Keeping the current behaviour of Indentured Servants still running away and staying flexible - less prone to errors by future balancing changes.)

    A) Additionally Checking Combat Strength (Unit +Profssion) (Fleeing Units are really weak)
    OR
    B) Additionally Checking UnitAI (Fleeing Units always have UnitAIFleeing)
     
    Last edited: Jul 29, 2020
  10. Aerials

    Aerials Chieftain

    Joined:
    Jul 26, 2020
    Messages:
    6
    Gender:
    Male
  11. devolution

    devolution Prince

    Joined:
    Oct 7, 2016
    Messages:
    385
    Gender:
    Male
    Location:
    Stavanger, Norway
    You are completely right, this is a bug LOL . It is simply too easy to be confused about the intersection\overlap of unit types and professions. I suppose that an additional check for canFight(), isArmed() or something like that would take care of it.
     
    raystuttgart likes this.
  12. Derek Brown

    Derek Brown Chieftain

    Joined:
    Apr 28, 2020
    Messages:
    21
    Gender:
    Male
    Location:
    Maui, Hawaii
    What if animal and Native XP farming had caps? Hopefully wouldn't be difficult to code:

    Animal XP farming - once unit has 8 XP, can no longer get XP from killing animals
    For natives - same thing but up to 15 XP

    That would make the most sense - a green unit can get some training but eventually see diminishing returns from easier targets
     
  13. devolution

    devolution Prince

    Joined:
    Oct 7, 2016
    Messages:
    385
    Gender:
    Male
    Location:
    Stavanger, Norway
    Already implemented. just set the XP cap to 8

    Interesting idea. It does make sense that massacring a bunch of scarcely clad spear-wielding semi-barbarians would get old at some point and stop granting XP.

    Patches \ PRs are welcome ;)
     
  14. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    Guys, let us stop overexaggerating with capping XP.

    XP capping for Runaways and Wild Animals was ok for me. (Even though I know that some people liked that XP farming.)
    XP capping for Natives goes too far though. (It really is a valid strategy to have Wars with Natives.)

    -----------

    What next?
    Will we cap XP from Colonial Combat Units?

    I know that a Human Player can get Military Units with 100+ XP that are essentially invincible Super Soldiers.

    But some Players really like that and work hard for it ingame to build up these Units.
    That is part of their fun and makes gameplay great for them.

    Have you ever seen how players usually react on XP caps in other games? (e.g. Baldurs Gate)
    It is always one of the most hated limitations and XP cap removers are one of the most downloaded "cheat tools".

    Yes, we have "GlobalDefines" to customizes such things for personal taste.
    But most casual players do not even know about them.

    -----------

    XP farming (and taking the gold) from Natives is a valid strategy if you e.g. play Spanish.
    AIso often enough AIs have Wars with Natives as well.

    Considering gameplay, immersion and even considering AI, I am completely against it. :nono:
    There is no valid reason to do it and we would just get complaints.

    Even the 2 existing XP caps are something that I am "just ok with" and accepted it because of immersion.
    They are still nothing that I really like because we took away 2 small gameplay strategies from players.

    I already did hurt my golden rule: "gameplay first" - unless it completely breaks performance, stability, balance, immersion ...
    XP caps have never made gameplay itself better in terms of fun in any game.

    We can not simply "dumb down" every single strategy that a Human Player can use better or more efficient than AI.
    In the end Player will not be able to do much more than moving his Units around ...
     
    Last edited: Jul 28, 2020
  15. Derek Brown

    Derek Brown Chieftain

    Joined:
    Apr 28, 2020
    Messages:
    21
    Gender:
    Male
    Location:
    Maui, Hawaii
    Ray - thanks for the reply. Yeah, your points make sense.

    What I was thinking was this along with tying together the other addition under discussion of unit maintenance. Ie if individual unit XP was capped for Natives (and maybe 15 was too low a number), if you wanted to fully capture all the XP that was to be had from a Native war, you'd have to field a decent size army (to spread around the XP to everyone) and expose yourself to unit maintenance costs, rather than build a small crack army of highly experienced super units for cheap. (Ie one strategy to reduce cumulative unit maintenance costs would be to develop good offensive super units in Native war and then ramp up late and get the city defense upgrade for newer units for WOI to take the hits). After reading your reply no longer sure my suggestion would be an improvement, but adding this to show the full thought process.
     
  16. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    See taking away gameplay strategies - even small ones - from Players is always a bad idea or at least needs to be considered very well.
    There need to be really good reasons to do so:
    • Is it overpowered considering other gameplay strategies?
    • Is it broken in terms of bugs or performance?
    • Does it completely destroy immersion?
    • ...
    Because someone out there got used to it and might even love it.
    When we take away such strategies we destroy their fun.

    ------

    When talking about "Upkeep of Military Units" there also need to stay valid strategic choices!

    1) Having a massive army with many unexperience troops.
    2) Having a small army with a few elite troops <--- Currently we are more or less talking about removing this.

    1) Is expensive but more easy to get
    2) Is cheaper but more difficult to get

    I have absolutely no intention to always force player to only use "massive untrained army" strategy.
    Having valid strategic choices is what makes a game interesting and fun! ;)
     
  17. raystuttgart

    raystuttgart Civ4Col Modder

    Joined:
    Jan 24, 2011
    Messages:
    5,699
    Gender:
    Male
    Location:
    Stuttgart, Germany
    @devolution
    If you do not mind, I will take care of this as well.

    Edit:
    It is fixed, tested and committed. :thumbsup:
     
    Last edited: Jul 29, 2020
    devolution likes this.

Share This Page