| version 1.3 | | version 1.4 |
|---|
| | |
| /* | | /* |
| * static char *rcsid_weather_c = | | * static char *rcsid_weather_c = |
| * "$Id: weather.c,v 1.3 2002/04/21 05:23:20 mwedel Exp $"; | | * "$Id: weather.c,v 1.4 2002/07/30 06:37:22 mwedel Exp $"; |
| */ | | */ |
| /* | | /* |
| CrossFire, A Multiplayer game for X-windows | | CrossFire, A Multiplayer game for X-windows |
| | |
| m->darkness = 0; | | m->darkness = 0; |
| for (i = HOURS_PER_DAY/2; i < HOURS_PER_DAY; i++) | | for (i = HOURS_PER_DAY/2; i < HOURS_PER_DAY; i++) |
| change_map_light(m, season_timechange[tod.season][i]); | | change_map_light(m, season_timechange[tod.season][i]); |
| for (i = 0; i < tod.hour; i++) | | for (i = 0; i <= tod.hour; i++) |
| change_map_light(m, season_timechange[tod.season][i]); | | change_map_light(m, season_timechange[tod.season][i]); |
| } | | } |
| | | |
| | |
| { | | { |
| mapstruct *m; | | mapstruct *m; |
| | | |
| | | /* If the light level isn't changing, no reason to do all |
| | | * the work below. |
| | | */ |
| | | if (season_timechange[tod->season][tod->hour] == 0) return; |
| | | |
| for(m=first_map;m!=NULL;m=m->next) { | | for(m=first_map;m!=NULL;m=m->next) { |
| #ifndef MAP_RESET | | #ifndef MAP_RESET |
| if (m->in_memory == MAP_SWAPPED) | | if (m->in_memory == MAP_SWAPPED) |