Git Update Log

Status
Not open for further replies.
New update: Fixed some bugs during game initialization.
 
New update:
- added some missing dynamic name text keys
- fixed dynamic names for vassals
- starting workers are also created when the first city is conquered
- fixes for Platybuilder event handlers
- minor civ name fixes
- different constants for Artillery tech and unit
- sugar is displayed in the Oil Industry tooltip for Brazil
 
New updates:
- fixed AP spawn during German autoplay
- reorganized text files
 
New update:
- fixed human immunity against first crisis
- fixed civic stability calculation
- fixed a Babylonian text key
- encouraged Phoenicia to found Qart Hadasht
 
New update: Fixed a bug occurring during city secession.
 
New update: extensive refactoring of DLL constants, exposing them to Python.

Full list of changes:
Spoiler :
  • All settler maps in CvRhyes.cpp have moved to SettlerMaps.py
  • All war maps in CvRhyes.cpp have moved to WarMaps.py
  • The region map and regional religion spread modifiers in CvRhyes.cpp have moved to RegionMap.py
  • All civilization modifiers in CvRhyes.cpp have moved to Modifiers.py
  • All constants influencing AI behavior (e.g. city placement) have moved to AIParameters.py
  • Every definition of civ specific information in CvRhyes.cpp (loading time, star ratings) have moved to CIV4CivilizationInfos.xml
  • The way text keys for interface stuff such as UHV texts are handled has been rewritten, the tedious specification of XML tags is now unnecessary, and they are automatically generated from the three letter key (i.e. EGY for Egypt) in CIV4CivilizationInfos.xml
  • Removed all starting era constants in CvRhyes.cpp. They were used to determine which era screens to show at the start of the game (i.e. only the most recent one), which happens dynamically with smarter code now, to control the starting era of cities (influencing initial size and buildings), which is now always one less than the player's current era, and for some effects on the scaling of tech costs, which is determined dynamically at the start of the game from the defined starting techs
  • Removed birth year constants from CvRhyes.cpp, they are initialized from the Python definition in Consts.py now
  • This leaves only the following constants defined in the DLL: religion persecution preference, religion persecution weights against other religions, era modifiers for tech cost rubberbanding. I have turned them into static variables and moved them to CvRhyes.h. CvRhyes.cpp has in turn been deleted. That is a huge unwieldy source file completely eliminated.
  • Made code that handles which civs have autoplay and which immediately start for a scenario dynamic, so explicit definition for every civ is not required anymore.
  • Other parts of the C++ code have been rewritten to remove manual array initialization and the like. This hopefully means that adding a new civ only requires one DLL change: upping the number of civ slots by one!
  • All previous DLL constants that have moved to Python are now persistently stored in either their player or plot object. Their value can be changed during the course of the game at any time. That means that none of the previous "constants" are actually constants anymore and instead be dynamic.
  • This allowed to remove tons of special cases baked into the DLL code (respawns, civs with changed modifiers after the discovery of Astronomy, scenario scaling ...), making the affected code much cleaner and easier to understand. I have also removed previously commented out legacy code (Rhye's) to further improve readability.
  • All constants that have moved to Python are now stored by civilization, not slot id. That made it much easier to store information for respawns, and no unnecessary double entries for respawned/unrespawned players is required. Respawns simply use the methods to change constants as soon as their civ changes (e.g. Aztec modifiers to Mexican modifiers).
  • All area related constants in Consts.py (capital, flip zone, core, normal and broader area) moved to Areas.py and changed from slot based to civ based. This to handle respawns in a similar way as above, removing duplicate entries. I have also rearranged their definition so that the TL and BR tuples are always right next to each other.
  • Streamlined and generalized different capital locations (start, relocation for AI, respawn) so that accessing code does not have to be aware of those differences, this should solve a couple of bugs with that.
  • Moved starting technologies from RiseAndFall.py to Civilizations.py to separate program logic and information, and to have all technologies in one place. This also initializes the starting era as mentioned above.
  • Implemented Areas.py in a way that a region can be queried and is returned as a plot list so that outside code does not have to be aware of the TL/BR rectangles or exception lists that may or may not exist. In turn, most Python code has been refactored to accept input as plot lists instead of TL, BR, exceptions triples.

Late addendum: this change breaks savegame compatibility.
 
Merged a pull request by Sgt. Bears fixing various dynamic names text keys.
 
Merged a pull request by merijn_v1 including various minor fixes:
Spoiler :
Fixed missing TXT key for Moors DCN
Fixed TXT key for Polynesian DCN
Fixed error in RFCUtils at makeUnit
Fixed bug when renaming city when being Harappa
Fixed Colombian leader
Fixed Civic screen resolution for lower screen resolutions (It's slighty smaller as well on higher resolutions, but it's still very well readable)
Pillaging with Corsair counts towards UHV


Merged a pull request by Sgt. Bears reordering text keys into files based on use.
 
Merged a pull request by Sgt. Bears correcting text keys and removing optional tags for unit XML.
 
Merged a pull request by Sgt. Bears containing further unit XML cleanup.
 
New update:
- Rome starts with City States
- several dynamic name fixes
- fixed a bug in the Congresses AI that prevented the AI from claiming plots for settlement (could lead to increased AI presence in Africa and Oceania again)
- China is displayed as a UHV target area for the Mongols
- removed a peak tile from the plots that receive a road when the silk route appears
 
Note: I forgot to mention that a previous change broke savegame compatibility, I have edited the post to that extent.
 
New update: fixed a Platybuilder bug that caused civic effects to be missing at the start of the game.
 
New update:
- era splash screen is not displayed if the civ starts in the ancient era
- dynamic names are correctly set at the start of the game
- farms are not displayed as removing rainforest for the Khmer
 
New update:
- correct expiration turn for the third Spanish UHV goal
- stricter conditions for full flips on respawn
- flipped cities now match the flip dialog
- add Aziz Sancar as a Turkish scientist
- Optics requires Machinery again
- fix a Python exception in the respawn code
- adjust continent boundaries so that Timbuktu's BFC is completely in Africa
 
Merged a pull request by Sgt. Bears including text fixes for actions, buildings and projects.
 
Merged a pull request by Sgt. Bears extending all references to jungles in the Python code to rainforests as well.
 
Merged a pull request by Sgt. Bears containing various unit XML fixes.
 
New update: Fixed a religion related bug in the player data WB.
 
Status
Not open for further replies.
Top Bottom