Maritime Weather+

Maritime Weather+ 4

Tekamthi

Emperor
Joined
Aug 12, 2016
Messages
1,909

Standalone (and improved) version of the ocean storms in Maritime Battles+....

This mod adds a Storm plot, and procedural rules for how this storm plot spawns and moves around the map:
Spoiler :
civ5mbpstorm-gif.689097


Storm plot rules
  • storm is a hybrid improvement/feature -- units can move through it like any other plot
  • 3 movement cost
  • blocks sight similar to forest/jungle
  • submarine ignores move cost
  • hover unit +1 extra move cost in plot
  • cannot be pillaged or removed by player
  • worker cannot start a build in a storm
  • city cannot be founded in a storm
"Season" mechanism:
  • storms spawn and move according to one of 4 sets of procedural rulesets
  • season rulesets are applied consecutively for a period of turns set according to map size and game speed (min 4, well into the 20s on larger maps and longer turn times)
  • season rulesets are applied per region, divided by latitude ie the equator and tropics
  • seasonal weather update events occur on rotating basis (ie on turn 1 weather updates on player 1's turn, turn 2 on player 2's etc.)
Spawn mechanism
  • there are 4 ocean spawn areas and 4 lake spawn areas, ie equator/tropic divisions
  • each season, storms will spawn in one ocean region and one lake region
  • storms may spawn in adjacent plots on a recursive basis, a storm spawn may involve just one plot or several
  • no spawns outside of ocean and lake plots (though recursive adjacency may grow a storm spawn into any eligible plot)
Move mechanism
  • storms may move to any adjacent plot with no improvement, feature, mountain, or worker build
  • possible move directions change per season (min 2 move options, max 3 move options)
  • storm that cannot move may despawn on % chance
  • storm that is over land and not adjacent to water may despawn on % chance
Bugfix mechanism - there is a bug in civ 5/vp that any feature in ocean allows early movement, even without required tech or other means of crossing ocean
  • any unit that should not be in ocean at end of turn is moved into adjacent coast closest to capital, or moved closer to capital continuously until in coast plot. Any storm plots through which the unit passes are removed.
  • this sometimes means a unit can take a shortcut across ocean -- think of it as a fortuitous wind
  • also serves as inadvertent unstuck mechanism for trapped recon with coast access
This was a component of another mod but has seen many changes, some of which were written by chatgpt o3-mini :lol: Treat as semi-experimental. I will change the version number to v4x if/when it is confirmed as viable for full-game.

Current state (v4): Tested for 100+ turns in observer mode on large map standard speed, no issues detected, storm amounts seem appropriate. So far, performance-hit is not noticeable. Road pillage chance is disabled by default but works if set in options. Several issues identified & eliminated in v2/3, both big and small; still have not observed in late-game, but may be in non-test, game-ready state.

 
Last edited:
Roadmap:

Planned:
  1. Observe & refine existing lua mechanism to optimize performance, ensure stable play into lategame, etc.
  2. adjust spawn & despawn rates for consistent effect across all maps & sizes etc.
  3. integrate storm spawn with vp events system, where appropriate (hurricane event etc.)
  4. fill out appropriate in-plot gameplay effects
    1. air units
    2. distinguish sail vs self-propelled units
    3. others?
  5. Rework model in blender to allow for a 2nd row of clouds, and fuller-looking storm plot
Speculative:
  • storm specializing promos/beliefs/buildings etc.
  • investigate whether ice art defines can be co-opted into improvement system for 'seasonal ice' plot
  • desert sand storm plot
  • fog plot
  • flood plot
  • wind mechanism
 
Last edited:
Tekamthi updated Maritime Weather+ with a new update entry:

more bugfixes, adjustments

sorry to anyone that started new game on last version -- problems for poly mainly, and also discovered other means of improving the mod:
  • 'storm fixer' function, intended to correct bug in civ 5/vp pre-astro ocean movement when features are present, was fixing units it shouldn't. fixed.
  • storms can now move over resources
  • submarine should be immune to storm movement cost
  • hover units should have extra move cost in storm

Read the rest of this update entry...
 
Hello I've started a game with version 2 and I'm at turn 200 now. I think it's a cool idea but I thought there would be more weather features other than only some tiles of storm that block vision and movement (this is partly my mistake as when I read 4 different seasons I thought there would be 4 different weather types or something akin to that). But well, overall I don't think it's very impactful at the moment. Granted, no one has a massive ship army in this game so naval combat has just been a few ships here and there; unsure if it makes big naval combat more interesting.
 
I thought there would be 4 different weather types
I'll try to clarify the OP for newcomers to understand what they're getting into. The seasons will only be noticeable if you really pay close attention to storm placement from turn to turn, though in some regions you'll notice that storms are fairly abundant at times and completely absent at others, depending on geography. The code involved here is a big upgrade from the previous pure-RNG it relied on. Though only recently broken off, this was theorycrafted in another naval-focused mod many years ago, and first implemented about 2-3 years ago -- perhaps my description presumes some knowledge of its evolution. The original purpose in this sense was simply to break up the monotony of vast samey ocean plots; as such it was only intended to be one layer of several naval effects. That remains its primary gameplay intention for now, and I will leave it to other mods to layer in things that render our naval game overall to where it should be; this effort is very much intended as a companion mod, a background mod...

Nonetheless will look into other features in the future -- there are no firm plans necessarily, its possible that this mod may remain 'just storms' for a long while. There are some possibilities for other things of which i am already aware, however: there is an effect that resembles a sand storm for example, which might bring some life to the deserts and surrounding terrain. I speculate that we might be able to co-opt the ice art defines via some means to have a 'temporary' version of ice, etc. There are only so many possibilities to re-purpose existing effects, and thats what these 'weather' effects rely on, so at best we will have 'some' weather features, but not everything we might want. Even so, feel free to make suggestions, no promises but will consider all good ideas, more detailed the better.

For me personally as a dedicated civ franchise player turned casual modder, this was probably one of the first mods i came to CF looking for for civ 5 (along with forests that grow) -- figured somehow someone must've found a way to make clouds and storms etc. Never found such, nor any way to accomplish it initially, and it was just an idea for many years. I probably sketched out the concept long ago in various threads, hoping someone more knowledgeable than I might pick it up -- my first reference to it in mb+ thread, labelled 'highly speculative', was back in early 2018! -- but there were no takers lol. Many years and much learning later, both on the model side and lua-wise, here we are finally with a basic procedural storm. So it may not look like all that much just yet, but a lot of heavy lifting is now out of the way, and the method of creating this effect will hopefully be source for more prominent things in the future. @ghost toast deserves honorable mention as he does with most of our 'modern' civ 5 on-map visual mods, and maybe will update our model even further for a fuller cloud? (hint hint :lol: its pretty awesome tho as-is)

My dev work will focus for now on making sure the storms and the code that runs them works really well and is viable in full play. Once thats all confirmed, it will be relatively trivial to use this framework to add more effects. That said i'm winding down on civ 5 dev stuff for now, so 'big' things will probably only be in summer or beyond. In the meantime, I'd welcome any other modders using the model developed here or in treesuccession to create more weather-like systems (between both we should be able to create on-ground and in-air effects). All of my code is also open for repurposing.

unsure if it makes big naval combat more interesting.

This is very much on-point to this mod's current focus -- I have applied some slightly more intricate rules in v4 -- possibly a big indirect buff to subs, we'll have to see how it plays. v4 also has more storms present inland than v2 (at least early on). Probably needs to affect air units as well though I haven't settled on exactly how yet.

I'd like this mod to have an effect that validly abstracts the effect of bad weather irl, and adds thematic value to the map -- we probably won't get down to distinguishing rain from snow, just storms, that level of detail -- aim is a moderately impactful gameplay effect dynamically-applied, while remaining ai-accessible. The relatively minor current effect is very ai accessible, they can pathfind around it just fine. If there are obvious effects the storms should have that are currently missing, those can be added in the short-term (assuming the db allows for it).

For other, non-weather naval-related things, I will look at those in the next revision of MB+, probably 2nd half of 2025.

edit: OP updated with functionality details
 
Last edited:
Back
Top Bottom