| version 1.26 | | version 1.27 |
|---|
| | |
| /* | | /* |
| * static char *rcsid_weather_c = | | * static char *rcsid_weather_c = |
| * "$Id: weather.c,v 1.26 2003/01/29 05:44:08 temitchell Exp $"; | | * "$Id: weather.c,v 1.27 2003/01/30 22:12:55 temitchell Exp $"; |
| */ | | */ |
| /* | | /* |
| CrossFire, A Multiplayer game for X-windows | | CrossFire, A Multiplayer game for X-windows |
| | |
| /* replace snow with a big puddle */ | | /* replace snow with a big puddle */ |
| remove_ob(tmp); | | remove_ob(tmp); |
| free_object(tmp); | | free_object(tmp); |
| at = find_archetype("rain5"); | | tmp=GET_MAP_OB(m, x, y); |
| | | if (!strcmp(tmp->arch->name, "mountain")){ |
| | | at = find_archetype("mountain1_rivlets");} |
| | | else if (!strcmp(tmp->arch->name, "mountain2")){ |
| | | at = find_archetype("mountain2_rivlets");} |
| | | else if (!strcmp(tmp->arch->name, "mountain4")){ |
| | | at = find_archetype("mountain2_rivlets");} |
| | | else {at = find_archetype("rain5");} |
| if (at != NULL) { | | if (at != NULL) { |
| ob = get_object(); | | ob = get_object(); |
| copy_object(&at->clone, ob); | | copy_object(&at->clone, ob); |
| | |
| continue; | | continue; |
| oldsnow = avoid_weather(&avoid, m, x, y, &gotsnow, 0); | | oldsnow = avoid_weather(&avoid, m, x, y, &gotsnow, 0); |
| if (!avoid) { | | if (!avoid) { |
| | | tmp=GET_MAP_OB(m, x, y); |
| | | if (!strcmp(tmp->arch->name, "mountain")){ |
| | | at = find_archetype("mountain1_rivlets"); break;} |
| | | else if (!strcmp(tmp->arch->name, "mountain2")){ |
| | | at = find_archetype("mountain2_rivlets"); break;} |
| | | else if (!strcmp(tmp->arch->name, "mountain4")){ |
| | | at = find_archetype("mountain2_rivlets"); break;} |
| if (sky == SKY_LIGHT_RAIN || sky == SKY_RAIN) { | | if (sky == SKY_LIGHT_RAIN || sky == SKY_RAIN) { |
| switch (rndm(0, SKY_HAIL-sky)) { | | switch (rndm(0, SKY_HAIL-sky)) { |
| case 0: at = find_archetype("rain1"); break; | | case 0: at = find_archetype("rain1"); break; |