Az időjárásokat nem fordítottam le neked de itt a lista:
0 = EXTRASUNNY_LA
1 = SUNNY_LA
2 = EXTRASUNNY_SMOG_LA
3 = SUNNY_SMOG_LA
4 = CLOUDY_LA
5 = SUNNY_SF
6 = EXTRASUNNY_SF
7 = CLOUDY_SF
8 = RAINY_SF
9 = FOGGY_SF
10 = SUNNY_VEGAS
11 = EXTRASUNNY_VEGAS (heat waves)
12 = CLOUDY_VEGAS
13 = EXTRASUNNY_COUNTRYSIDE
14 = SUNNY_COUNTRYSIDE
15 = CLOUDY_COUNTRYSIDE
16 = RAINY_COUNTRYSIDE
17 = EXTRASUNNY_DESERT
18 = SUNNY_DESERT
19 = SANDSTORM_DESERT
Itt a script amit most összedobtam neked:
#include <a_samp>
forward Idojaras();
public OnFilterScriptInit()
{
SetTimer(\"Idojaras\", 60000*30, true);
return 1;
}
public Idojaras() {
new rand = random(21), string[144];
SetWeather(rand);
format(string, sizeof(string), \"Időjárás jelentés: Jelenlegi időjárás: %s\", GetIdojaras(rand));
SendClientMessageToAll(-1, string);
return 1;
}
stock GetIdojaras(weatherid) {
new idojaras[32];
switch(weatherid) {
case 0: idojaras = \"\";
case 1: idojaras = \"\";
case 2: idojaras = \"\";
case 3: idojaras = \"\";
case 4: idojaras = \"\";
case 5: idojaras = \"\";
case 6: idojaras = \"\";
case 7: idojaras = \"\";
case 8: idojaras = \"\";
case 9: idojaras = \"\";
case 10: idojaras = \"\";
case 11: idojaras = \"\";
case 12: idojaras = \"\";
case 13: idojaras = \"\";
case 14: idojaras = \"\";
case 15: idojaras = \"\";
case 16: idojaras = \"\";
case 17: idojaras = \"\";
case 18: idojaras = \"\";
case 19: idojaras = \"\";
case 20: idojaras = \"\";
}
return idojaras;
}
Értelem szerűen sorrendbe írd be az időjárások megnevezéseit (
idojaras = \"\";) és kész is a dolog.