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

ModModder's Guide

Discussion in 'Rise from Erebus Modmod' started by Valkrionn, Jul 31, 2010.

  1. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    Defaults are in CvInfos, in the source files. bSinglePlayer defaults to False, so 0.

    And I have no idea. :lol:
     
  2. GIR

    GIR It'sNotStupidIt'sAdvanced

    Joined:
    Jul 12, 2005
    Messages:
    880
    Location:
    EU
    Would it be possible to use the "Broader Alignments" option in combination with Traits and/or Civics?
    At the moment I can switch Broader Alignments on and off whenever I want (it with python) but it affect all players. It would be awesome if only the player with the proper civic or trait is affected by this.
     
  3. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    Not really; Post 1.4, we'll likely remove the option to disable Broader Alignments. The thing it has been waiting on most, has been full integration into the game... And what better time to do that then while redesigning virtually everything else?

    What exactly do you want to use it for? It should be possible to use the Player/City variables to emulate BA for a single player only; pPlayer.getCivCounter/getCivCounterMod, and pCity.getCityCounter/getCityCounterMod. If you use the second on, say, the capital, it should work pretty easily.... So long as the civ isn't already using them.
     
  4. GIR

    GIR It'sNotStupidIt'sAdvanced

    Joined:
    Jul 12, 2005
    Messages:
    880
    Location:
    EU
    Strange modular xml behavior:

    I use the "GWS Buildings" module and found a strange bug with the BAZAAR_OF_MAMMON.

    For this test I use rife 1.31.195 with only the "BannorChainofCommand" and "GWS Buildings" module.
    In "GWS Buildings" the BAZAAR_OF_MAMMON is changed from a nat. wonder to a 'normal' wonder.

    this is in the original rife xml file (CIV4BuildingClassInfos.xml):
    Code:
    		<BuildingClassInfo>
    			<Type>BUILDINGCLASS_BAZAAR_OF_MAMMON</Type>
    			<Description>TXT_KEY_BUILDING_BAZAAR_OF_MAMMON</Description>
    			<iMaxGlobalInstances>-1</iMaxGlobalInstances>
    			<iMaxTeamInstances>-1</iMaxTeamInstances>
    			<iMaxPlayerInstances>1</iMaxPlayerInstances>
    			<iExtraPlayerInstances>0</iExtraPlayerInstances>
    			<bNoLimit>0</bNoLimit>
    			<bMonument>0</bMonument>
    			<DefaultBuilding>BUILDING_BAZAAR_OF_MAMMON</DefaultBuilding>
    			<VictoryThresholds/>
    		</BuildingClassInfo>
    
    and this is whats in the GWS modular file:

    Code:
    		<BuildingClassInfo>	
    			<Type>BUILDINGCLASS_BAZAAR_OF_MAMMON</Type>
    			<iMaxGlobalInstances>1</iMaxGlobalInstances>
    			<iMaxTeamInstances>-1</iMaxTeamInstances>
    			<iMaxPlayerInstances>-1</iMaxPlayerInstances>
    		</BuildingClassInfo>
    
    but with just this in the modular file you cant build the wonder.
    in the civilopedia you will see a msg: Cannot be built by any civilization

    the crazy thing is if you copy the last four lines of the 'original' rife lines into the module the wonder works fine. what's going on?

    Code:
    		<BuildingClassInfo>	
    			<Type>BUILDINGCLASS_BAZAAR_OF_MAMMON</Type>
    			<iMaxGlobalInstances>1</iMaxGlobalInstances>
    			<iMaxTeamInstances>-1</iMaxTeamInstances>
    			<iMaxPlayerInstances>-1</iMaxPlayerInstances>
    			
    [COLOR="Red"]			<iExtraPlayerInstances>0</iExtraPlayerInstances>
    			<bNoLimit>0</bNoLimit>
    			<bMonument>0</bMonument>
    			<DefaultBuilding>BUILDING_BAZAAR_OF_MAMMON</DefaultBuilding>
    			<VictoryThresholds/>[/COLOR]
    			
    		</BuildingClassInfo>
    
     
  5. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    Defaults may not be correct, I'll check it out.
     
  6. The Flame8

    The Flame8 Chieftain

    Joined:
    Dec 17, 2009
    Messages:
    568
    Location:
    United States
    Can someone make the momus scenario compatible with Rise from Erebus? Also, is it possible to make momus, and being able to use anyone in it against anyone. That would be awesome.
     
  7. GIR

    GIR It'sNotStupidIt'sAdvanced

    Joined:
    Jul 12, 2005
    Messages:
    880
    Location:
    EU
    i try to add a new popup (with picture) like Kael did in his "[TUTORIAL] HOW TO: Add Popups" thread (link: http://forums.civfanatics.com/showthread.php?t=183126).

    is this possible in a modular way (need to add stuff in CvScreensInterface.py) or do i have to use the BTS EVENT system for things like that?
     
  8. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    CvScreensInterface.py is not modular, unfortunately. Not sure one of the interface files should be (far too easy to kill things).
     
  9. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Hi,

    I'm working on nomadic civilization. In my initial tests using Vanilla FFH, I was able to have the option of choosing cities or settlements when a city was founded by setting <iMaxCities> in the TraitInfos to a positive value. I'm now trying to get my mod to work with RifE setting the <iMaxCities> value does not seem to give the settlement option. Any idea why?

    LPlate
     
  10. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    I'll have to look into this once I get home. Looks like it should be working, according to the sourceforge code; Could you post the full trait info?
     
  11. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Trait works fine. Works even better now that I've assigned it to the Civilization.:wallbash:

    LPlate
     
  12. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Hi,

    Are there any plans to modularise the python for 'onCityAcquiredAndKept'?

    I thought, given the selfish, tribal attitudes of my nomadic civilization, killing off the entire population of a newly conquered city but keeping it as an Off-Season Settlement would make sense.

    LPlate
     
  13. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    I think it already is...

    Yep, just checked, and it shows as modular in my files.
     
  14. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Thanks.
     
  15. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Hi,

    Is onCultureExpansion modular or will it be? I didn't see the modular references in CvEventManager for this function.
     
  16. arcticnightwolf

    arcticnightwolf Chieftain

    Joined:
    Jun 8, 2008
    Messages:
    1,301
    Location:
    Prague, Czech Republic
    onCultureExpansion is modular
     
  17. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
    Yes and no.

    It is NOT modular in the latest patch.

    It IS modular in the latest SVN, both Development and Public. As are all functions, IIRC.
     
  18. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Hi,

    What's SVN?
     
  19. Valkrionn

    Valkrionn The Hamster King

    Joined:
    May 23, 2008
    Messages:
    14,450
    Location:
    Crestview FL
  20. Lplate

    Lplate Esus (Allegedly)

    Joined:
    Feb 8, 2011
    Messages:
    578
    Location:
    Ireland
    Will there be pyPreCombat callbacks in 1.4?
     

Share This Page