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

Repost: How do I mod out some aspects of Rhye's and Fall?

Discussion in 'Civ4 - Rhye's and Fall of Civilization' started by Taiyama, Oct 31, 2009.

  1. Taiyama

    Taiyama Chieftain

    Joined:
    Feb 26, 2009
    Messages:
    38
    Location:
    U.S.A.
    First off, this is a repost of a similar topic I put in the wrong forum. If I should have just waited on a mod to move it, I apologize, but I made the mistake of explaining why I wanted to get rid of the third thing and someone who disagreed with me took offense; so I really just wanted to recreate the thread and not have that kind of off-topic stuff in it.

    All right, Rhye's and Fall is pretty much the only part of Civ IV that keeps me playing after such a long addiction to the game that waned over time. I really adore taking a civilization from its historical roots and making it the same as or different than what it was historically. However, there are three aspects of the mod that I would like to know how to get rid of and since I'm about as computer savvy as a crumbled plastic cup, I've decided to ask here.

    1. I'd like to get rid of the negative stability modifiers for Representation if you have over three cities. I KINDA understand the reasoning behind this--many believe that the Roman Republic fell partially because it couldn't handle the administration of such a huge empire--but the thing is, the United States of America proved the whole "A Republic cannot be large" thing wrong, so I'd like to get rid of it.

    2. Additionally, I'd like to get rid of the negative modifiers against number of cities, period. I understand the ones that give negative modifiers if you go outside historic expansion, but these just annoy me when I'm trying to, say, build the British Empire to its historical heights.

    3. I'd like to get rid of the Great Depression aspect if you have the "Free Market" civic. This is the troublesome one. Not explaining why I want this one out this time.

    Anyway, if someone would kindly answer my question, I would very much appreciate it.
     
  2. Cethegus

    Cethegus King

    Joined:
    Feb 28, 2008
    Messages:
    922
    Location:
    Finland
    1. Go to RFC's Assets->Python folder and open Stability.py in a notepad program. Search for 'represent' and delete the whole paragraph of the corresponding find - this one.

    Make sure you leave only one empty row between the above and below paragraphs,
     
  3. Taiyama

    Taiyama Chieftain

    Joined:
    Feb 26, 2009
    Messages:
    38
    Location:
    U.S.A.
    Thank you very much for the help, Cethegus. I've done as you asked. Any idea how to do the other two?
     
  4. Jaguar

    Jaguar Lurker

    Joined:
    Aug 9, 2004
    Messages:
    292
    What I've always really wanted to do is tone down the giga-empire tech penalty so I can create large colonial empires, but that involves modding .dll files.
     
  5. Taiyama

    Taiyama Chieftain

    Joined:
    Feb 26, 2009
    Messages:
    38
    Location:
    U.S.A.
    As I said above, I'm as computer savvy as a crumbled plastic so I have NO idea what you're talking about, Jaguar. Thanks for the bump, though.

    And if anyone sees this and has time, maybe they can answer your question too.
     
  6. Tibur753

    Tibur753 Leigonary

    Joined:
    May 26, 2008
    Messages:
    513
    The code for giga-empires is in the dll, not python like the representation penalty. It is more complicated to edit this because you have to recompile the files for the change to go into effect.

    The great depression can be removed by commenting out lines 797 through 802 of stability.py. You can comment out a line by putting a # at the beginning, this causes the computer to overlook that line of code. You would do this as opposed to deleting the code so that you can undo the changes if you wanted to.
     
  7. laxpimpj

    laxpimpj Chieftain

    Joined:
    Apr 28, 2004
    Messages:
    56
    id really like to attempt a giga empire game without the neg stability and neg tech penalty. Is there anyone out there that has already "recompiled the .dll" that could post it online? Like the OP I am not very computer savvy.
     
  8. laxpimpj

    laxpimpj Chieftain

    Joined:
    Apr 28, 2004
    Messages:
    56
    so anyone have any instructions on how to do this?
     
  9. Jaguar

    Jaguar Lurker

    Joined:
    Aug 9, 2004
    Messages:
    292
    Sorry, I don't check this forum much now that the mod is essentially completed.

    Here's my recompiled .dll.

    Let me be exactly clear on what this does:

    The normal tech penalty for giga-empires is that for each city beyond the tenth, the cost of tech goes up by 8%. That is to say that an empire of 10 cities has the typical tech cost. An empire of 12 cities has a tech cost of 116% of the usual cost. An empire of 13 cities has a tech cost of 124%. And an empire of 50 cities has a whopping 420% tech cost.

    In this file, the 8% has been changed to 2%. So that same empire of 50 cities researches techs at a mere 180% of the cost.

    Further note: this change applies only to the human player. The AI's tech costs are governed in a different part of the code.

    CvGameCoreDLL.dll can be found in the /Assets folder of the RFC folder. Be sure to make a backup, in case something goes awry. I have only used this with the most updated version of RFC.

    http://uploading.com/files/4559de61/CvGameCoreDLL.dll/
     
  10. laxpimpj

    laxpimpj Chieftain

    Joined:
    Apr 28, 2004
    Messages:
    56
    Thanks Jaguar, appreciate it!
     
  11. evran

    evran Chieftain

    Joined:
    Sep 3, 2008
    Messages:
    77
    Is your file posted in the Modmods section, it should be. Anyways I thought I'd ask my question here instead of making a new thread. How do I mod out the auto war when spawned. America is slightly harder now because England/France/Spain are most time at auto war with me and they don't declare war when I flip their cities giving me all those good units... would this be in python or .dll?
     
  12. laxpimpj

    laxpimpj Chieftain

    Joined:
    Apr 28, 2004
    Messages:
    56
    Does anyone know how to mod out the negative stability points your receive for razing cities?
    Is it python or .dl?
     
  13. laxpimpj

    laxpimpj Chieftain

    Joined:
    Apr 28, 2004
    Messages:
    56
    I found this line, but I am not sure what to do with it...


    def onCityRazed(self, iOwner, playerType, city):

    if (iOwner < con.iNumPlayers):
    self.setStability(iOwner, self.getStability(iOwner) - 3 )
    #print("Stability - city razed", -3, iOwner)
    self.setParameter(iOwner, iParExpansionE, True, - 3)

    if (playerType < con.iNumPlayers):
    iTempExpansionThreshold = self.getStability(playerType)
    if (gc.getPlayer(playerType).getCivics(5) == 28):
    self.setStability(playerType, self.getStability(playerType) - 2 ) #balance the +2 and makes 0 for city razed
    self.setParameter(playerType, iParExpansionE, True, self.getStability(playerType) - iTempExpansionThreshold)
     
  14. Ready_set_go

    Ready_set_go Too Late

    Joined:
    Jun 21, 2009
    Messages:
    333
    Location:
    Massachusetts, USA
    Is there a simple thing just to get rid of stability, with the ability to put it back in without much trouble?
     
  15. Tibur753

    Tibur753 Leigonary

    Joined:
    May 26, 2008
    Messages:
    513
    @laxpimpj

    The code that you posted doesn't appear to contain the penalty for razing a city. It just delivers an additional penalty to the previous owner of the city and removes the bonus that would have been received from the occupation civic by the conqueror had he kept the city. I'm not sure where exactly the city razing penalty is coded in but I would guess it's somewhere in python, someone else might know where.

    @evran

    Look for the method warOnSpawn in RiseAndFall.py. This controls wars on spawn and Rhye has conveniently provided a simple way to remove this mechanic. By changing line 8 of the method from iMin = 20 to iMin = 100, the function will skip the human. If you want it to skip the AI also, you can do the same to line 6.
     
  16. Ready_set_go

    Ready_set_go Too Late

    Joined:
    Jun 21, 2009
    Messages:
    333
    Location:
    Massachusetts, USA
    Is there somwhere in the code which turns Stability on or off?
    Or is there anyway to add a line like that?
     
  17. laxpimpj

    laxpimpj Chieftain

    Joined:
    Apr 28, 2004
    Messages:
    56
    Ditto
     
  18. Ready_set_go

    Ready_set_go Too Late

    Joined:
    Jun 21, 2009
    Messages:
    333
    Location:
    Massachusetts, USA
    Still no answer ?
     
  19. blizzrd

    blizzrd Micromanager

    Joined:
    Dec 27, 2005
    Messages:
    3,738
    Location:
    Melbourne, Australia
    Do a search of this forum and you will find what you seek. Please stop bumping this thread and try the search function.
     
  20. Cethegus

    Cethegus King

    Joined:
    Feb 28, 2008
    Messages:
    922
    Location:
    Finland
    Has someone else noticed that it almost always seems to be a Mehmed II leaderhead avatar who keeps asking this every time it's brought up?

    For the person himself, I'm not trying to be unpolite, it's just a surprising and a bit frustrating coinsidence. Seriously, use the search function.
     

Share This Page