Resource icon

[BtS 3.17] JUnitSpace v0.693: Limited Units on Til 2016-10-05

JUnitSpace Mod
by Jeckel

This mod allows you to set a default amount of Space that a Tile has.
Bonuses, Features, Improvements, Routes, Terrain, City Buildings, City Culture Levels, City Population, and Cities themselves can be
configured to modify the default Tile Space with new tags in their Info.xml files.

Units ave a default Size set in the UnitClassInfo.xml.
A Unit's default Size can be modified by a tag in the UnitInfo.xml.
In the UnitInfos you can also set Units to ignore the Tile Space Rules or just
the Tile Space Limit.

Promotions can now allow Units to ignore the Tile Space Limit as well as modifing a Unit's Size.

Both CivilizationInfo and LeaderHeadInfo now have new tags to exclude them from the Tile Space Rules.
If a UnitInfo, CivilizationInfo, or LeaderHeadInfo are set to ignore Tile Space Rules then a Unit object
will ignore the rules.
By default both the Barbarian Civilization and the Barbarian Leader are set to ignore Tile Space Rules.

New Global Defines have been added to enable/disable various Tile Space Modifiers.
There are also Global Defines to control City Tiles and City Unit Training.
Global Defines are included to exclude Land, Sea, Air, and/or Immobile Unit Domains.

All Pedia pages have been updated in the SDK to show the new data.
This data will also show on all the flying help tests.
When the cursor is held over a plot in the main interface the Open Space and the Total Space of a Tile
will be displayed.
On the main interace a selected Unit's Size will be displayed after its Movement and before its Level.


By pressing SHIFT + S with the cursor over a plot you will see a popup with a break down of
Tile Space math.


A simple scenario is included that will allow easy testing of many of the different Tile Space situations.

New XML Tags (All New Tags Are Optional)
Spoiler :
All changes marked with:
<!-- JUnitSpace Mod Start -->
<!-- JUnitSpace Mod End -->

CIV4CivilizationInfos.xml
-bIgnoreTileSpaceRules

CIV4LeaderHeadInfos.xml
-bIgnoreTileSpaceRules

CIV4UnitClassInfos.xml
-iDefaultUnitSize

CIV4UnitInfos.xml
-iUnitSize
-bIgnoreTileSpaceLimit
-bIgnoreTileSpaceRules

CIV4BonusInfos.xml
-iTileSpaceChange

CIV4FeatureInfos.xml
-iTileSpaceChange

CIV4ImprovementInfos.xml
-iTileSpaceChange

CIV4TerrainInfos.xml
-iTileSpaceChange

CIV4PromotionInfos.xml
-iTileSpaceChange
-bIgnoreTileSpaceLimit

CIV4BuildingInfos.xml
-iTileSpaceChange

CIV4CultureLevelInfos.xml
-iTileSpaceChange


Python Changes
Spoiler :
I modded the MainInterface.py and the PediaUnit.py files.
I added a new Screen.
I also use Dr. Elmer Jiggles CustomEventManager to catch the SHIFT + S event
to launch my new screen.

Lots of new methods to access all the new data.
Check out the new screen to see some of them in use.


SDK functions added and Exposed to Python
Spoiler :
All changes marked with:
// < JUnitSpace Mod Start >
// < JUnitSpace Mod End >

CyCivilizationInfo
-bool isIgnoreTileSpaceRules()

CyLeaderHeadInfo
-bool isIgnoreTileSpaceRules()

CyUnitClassInfo
-int getDefaultUnitSize()

CyUnitInfo
-int getUnitSize()
-int getBaseUnitSize()
-bool isIgnoreTileSpaceLimit()
-bool isIgnoreTileSpaceRules()

CyBonusInfo
-int getTileSpaceChange()

CyFeatureInfo
-int getTileSpaceChange()

CyImprovementInfo
-int getTileSpaceChange()

CyTerrainInfo
-int getTileSpaceChange()

CyPromotionInfo
-int getUnitSizeChange()
-bool isIgnoreTileSpaceUnit()

CyBuildingInfo
-int getTileSpaceChange()

CyCultureLevelInfo
-int getTileSpaceChange()

CyUnit
-int getUnitSize()
-int getTotalUnitSize()
-int getExtraUnitSize()
-bool ignoreTileSpaceLimit()
-bool ignoreTileSpaceRules()

CyPlot
-int getBaseTileSpace()
-int getTileSpace()
-int getBonusSpaceChange()
-int getFeatureSpaceChange()
-int getImprovementSpaceChange()
-int getTerrainSpaceChange()
-int getCityBuildingSpaceChange()
-int getCityCultureLevelSpaceChange()
-int getHillSpaceChange()
-int getUsedTileSpace(bool bCountCargo)
-int getOpenTileSpace(bool bCountCargo)
-bool isTileSpaceFull(bool bCountCargo)


JUnitSpace Mod Thread
Author
Jeckel
Downloads
748
Views
748
First release
Last update
Rating
4.00 star(s) 4 ratings

More resources from Jeckel

Top Bottom