TC01
Deity
Blizzards Modcomp v1.1
For Fall Further 0.51c
This python-only modcomp adds Age of Ice style blizzards to Fall Further. If you haven't played AoI, Blizzards were able to move around and spread snow terrain in that scenario. FFH 2 (and Fall Further) lacks this feature. However, for my Frozen new civ mod I wanted to add a method of "automatically spreading" snow terrain- and thought of blizzards. So, I'm releasing this modcomp with only the Blizzard code in it. It will be included in the next version of the Frozen civilization, however I also released a version for Fall from Heaven 2, and now am releasing a version of Blizzards for Fall Further, with some slight changes. Now, Blizzards also temporarily remove livestock and grain resources, and temporarily apply ice to water plots like they do to land plots.
Blizzards is done entirely in python, thus making merging it with another mod very easy (especially since all of my new code, save a few lines in the event manager and spell interface files, is in a new python file, Blizzards.py). There are instructions for using it with another mod of Fall Further below under the Install Instructions, and are also included in a file in the download.
What I've Made Blizzards Do: (New items in v1.1 are in blue)
-Allowed blizzards to move around the map (they are blocked by features)
-Allowed blizzards to be randomly spawned on snow plots in Illian terrain.
-Blizzards randomly spread both temporary and permanent snow terrain
-Blizzards randomly spread both temporary and permanent ice on water plots
-Blizzards will randomly be destroyed (naturally)
-The Call Blizzard ability applies the code ran by the blizzard to set ice terrain
-Certain resources, grain and livestock, will be temporarily destroyed by a passing blizzard
-Scorch can remove water ice within a one-plot radius of the caster.
Links:
Download Here
Blizzards for Fall From Heaven 2
Changelog:
To Install:
1. Unzip the files into a temporary directory.
2. Copy the Python folder into your Beyond the Sword\Mods\Fall Further 051\Assets folder. You may wish to back up your existing files or create a new "FF Blizzards" folder in Beyond the Sword\Mods that is a copy of the Fall Further folder, and copy the Python folder from the zip into there. Either method will work.
3. To test, start a game as the Illians and make all plots around you Snow terrain via Worldbuilder. Blizzards should start spawning on them if you have installed the mod correctly.
You can also customize this mod to change the rate of blizzards spreading, moving, spawning, or dying, change the type of plots blizzards can move onto or be spawned on, or change how the terrain changes when a blizzard moves. See the Blizzards.py file in the Python folder for more information.
To install this with another modmod, you can either use the Merging Guide included in the mod or the instructions below.
1. Copy the Blizzards.py file from the modcomp into [FF_MOD]\Assets\Python, where [FF_MOD] is the mod you are trying to merge this with. (For instance,
Tears 051c\Assets\Python).
2. Open CvEventManager.py, located in Assets\Python, using a text editor such as Notepad++ (but Notepad works as well).
3. At the top of the file, between the import statements (for instance, import OOSLogger, import Util, etc.) and a line saying # Globals, add this line:
4. Below where it says # Globals, add the following line of code:
5. In the onBeginGameTurn function, add the following line of code at the end of the function.
6. Close CvEventManager.py and open the file CvSpellInterface.py, located in Assets\Python\Entrypoints.
7. At the top of the file, below the import statements, add the following line:
8. Below the globals, add the following line of code:
9. Overwrite the spellCallBlizzard function with this code:
10. At the bottom of the spellScorch function, add this code:
11. Close CvSpellInterface.py and test it out as described in the install directions.
Credits:
-TC01
-MagisterCultuum, Cypher, xienwolf (help)
-Valkrionn, Breez (feedback)
-Fall Further Mod Team (for making FF)
-Fall from Heaven 2 Mod Team (for making FFH 2)
-Firaxis (for making Civ IV)
Screenshots:
On the download page, there are three screenshots, of Turn 0, Turn 5, and Turn 10, to show the effect of a blizzard. I have worldbuildered a blizzard on Turn 0 on the coast by some plains. By Turn 5, the Blizzard has spread snow and ice in a small region around the plot where I Worldbuildered it. By Turn 10, you can see that the blizzard has faded, and one of the plots has reverted back to normal terrain (as it must have been a temporary change). Note that they were taken with the FFH 2 version.
For Fall Further 0.51c
This python-only modcomp adds Age of Ice style blizzards to Fall Further. If you haven't played AoI, Blizzards were able to move around and spread snow terrain in that scenario. FFH 2 (and Fall Further) lacks this feature. However, for my Frozen new civ mod I wanted to add a method of "automatically spreading" snow terrain- and thought of blizzards. So, I'm releasing this modcomp with only the Blizzard code in it. It will be included in the next version of the Frozen civilization, however I also released a version for Fall from Heaven 2, and now am releasing a version of Blizzards for Fall Further, with some slight changes. Now, Blizzards also temporarily remove livestock and grain resources, and temporarily apply ice to water plots like they do to land plots.
Blizzards is done entirely in python, thus making merging it with another mod very easy (especially since all of my new code, save a few lines in the event manager and spell interface files, is in a new python file, Blizzards.py). There are instructions for using it with another mod of Fall Further below under the Install Instructions, and are also included in a file in the download.
What I've Made Blizzards Do: (New items in v1.1 are in blue)
-Allowed blizzards to move around the map (they are blocked by features)
-Allowed blizzards to be randomly spawned on snow plots in Illian terrain.
-Blizzards randomly spread both temporary and permanent snow terrain
-Blizzards randomly spread both temporary and permanent ice on water plots
-Blizzards will randomly be destroyed (naturally)
-The Call Blizzard ability applies the code ran by the blizzard to set ice terrain
-Certain resources, grain and livestock, will be temporarily destroyed by a passing blizzard
-Scorch can remove water ice within a one-plot radius of the caster.
Links:
Download Here
Blizzards for Fall From Heaven 2
Changelog:
Code:
v1.1 Changelog:
-Scorch can now remove water ice within a one-plot radius of the caster
-An additional check added for water to even have a chance of getting ice, temporary or permanent
-Resources in Illian territory are no longer swallowed by Blizzards
-An extra chance added for blizzards to die outside of Illian territory
-Blizzard death chance increased, blizzard creation chance decreased
-Blizzard movement chance and chance of permanent snow terrain being created lowered slightly
To Install:
1. Unzip the files into a temporary directory.
2. Copy the Python folder into your Beyond the Sword\Mods\Fall Further 051\Assets folder. You may wish to back up your existing files or create a new "FF Blizzards" folder in Beyond the Sword\Mods that is a copy of the Fall Further folder, and copy the Python folder from the zip into there. Either method will work.
3. To test, start a game as the Illians and make all plots around you Snow terrain via Worldbuilder. Blizzards should start spawning on them if you have installed the mod correctly.
You can also customize this mod to change the rate of blizzards spreading, moving, spawning, or dying, change the type of plots blizzards can move onto or be spawned on, or change how the terrain changes when a blizzard moves. See the Blizzards.py file in the Python folder for more information.
To install this with another modmod, you can either use the Merging Guide included in the mod or the instructions below.
Spoiler Merging Guide :
1. Copy the Blizzards.py file from the modcomp into [FF_MOD]\Assets\Python, where [FF_MOD] is the mod you are trying to merge this with. (For instance,
Tears 051c\Assets\Python).
2. Open CvEventManager.py, located in Assets\Python, using a text editor such as Notepad++ (but Notepad works as well).
3. At the top of the file, between the import statements (for instance, import OOSLogger, import Util, etc.) and a line saying # Globals, add this line:
Code:
import Blizzards
4. Below where it says # Globals, add the following line of code:
Code:
Blizzards = Blizzards.Blizzards()
5. In the onBeginGameTurn function, add the following line of code at the end of the function.
Code:
Blizzards.doBlizzardTurn()
6. Close CvEventManager.py and open the file CvSpellInterface.py, located in Assets\Python\Entrypoints.
7. At the top of the file, below the import statements, add the following line:
Code:
import Blizzards
8. Below the globals, add the following line of code:
Code:
Blizzards = Blizzards.Blizzards()
9. Overwrite the spellCallBlizzard function with this code:
Code:
def spellCallBlizzard(caster):
iBlizzard = gc.getInfoTypeForString('FEATURE_BLIZZARD')
iTundra = gc.getInfoTypeForString('TERRAIN_TUNDRA')
iX = caster.getX()
iY = caster.getY()
pBlizPlot = -1
for iiX in range(iX-1, iX+2, 1):
for iiY in range(iY-1, iY+2, 1):
pPlot = CyMap().plot(iiX,iiY)
if pPlot.getFeatureType() == iBlizzard:
pBlizPlot = pPlot
if pBlizPlot != -1:
pBlizPlot.setFeatureType(-1, -1)
pPlot = caster.plot()
pPlot.setFeatureType(iBlizzard, 0)
Blizzards.doBlizzard(pPlot)
10. At the bottom of the spellScorch function, add this code:
Code:
for iiX in range(pPlot.getX()-1, pPlot.getX()+2):
for iIY in range(pPlot.getY()-1, pPlot.getY()+2):
pIce = CyMap().plot(iiX, iiY)
if pIce.getFeatureType() == gc.getInfoTypeForString('FEATURE_ICE'):
pIce.setFeatureType(-1, -1)
11. Close CvSpellInterface.py and test it out as described in the install directions.
Credits:
-TC01
-MagisterCultuum, Cypher, xienwolf (help)
-Valkrionn, Breez (feedback)
-Fall Further Mod Team (for making FF)
-Fall from Heaven 2 Mod Team (for making FFH 2)
-Firaxis (for making Civ IV)
Screenshots:
On the download page, there are three screenshots, of Turn 0, Turn 5, and Turn 10, to show the effect of a blizzard. I have worldbuildered a blizzard on Turn 0 on the coast by some plains. By Turn 5, the Blizzard has spread snow and ice in a small region around the plot where I Worldbuildered it. By Turn 10, you can see that the blizzard has faded, and one of the plots has reverted back to normal terrain (as it must have been a temporary change). Note that they were taken with the FFH 2 version.