added an option to disable storms from configuration files

This commit is contained in:
Enno Rehling 2012-07-08 23:15:22 -07:00
parent 366f0feeaa
commit 3fda0ab144
1 changed files with 6 additions and 3 deletions

View File

@ -1720,9 +1720,12 @@ sail(unit * u, order * ord, bool move_on_land, region_list ** routep)
int reason;
if (gamecookie != global.cookie) {
bool storms_enabled = get_param_int(global.parameters, "rules.ship.storms", 1)!=0;
if (storms_enabled) {
gamedate date;
get_gamedate(turn, &date);
stormyness = storms[date.month] * 5;
}
gamecookie = global.cookie;
}