Problem(error/warning): Zna li neko kako da resim ova dva errora koristim sacramento skriptu
Dio skripte:
YCMD:staff(playerid, params[], help)
format(text, sizeof(text), "{AA3333}Offline (%dh)", HelperInfo[tesNeakt]);
strcat(lideri, atext);
format(text, sizeof(text), "{21DD00}DutyTime: {FFFFFF}%dmin\n", HelperInfo[tesDutyTime]);
strcat(lideri, atext);
Debug iz server_log(ukoliko je u pitanju crashanje servera - crashdetect log):
Slika/video ingame problema(obavezno ako je ingame problem):
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88311) : error 017: undefined symbol "text"
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88311) : error 017: undefined symbol "text"
TO SU ERRORI
new text[60];
kad stavim [pawn]new text[60];[/pawn] rese se oba errora al se pojavi ovaj
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88311) : error 003: declaration of a local variable must appear in a compound block
Preimenuj ih u text pobrisi atext pa probaj
isti error se pojavljuje
daj mi liniju 88311 pozuri moram da idem
[pawn] new text[60];[/pawn]
YCMD:staff(playerid, params[], help)
new text[60];
format(text, sizeof(text), "{AA3333}Offline (%dh)", HelperInfo[tesNeakt]);
strcat(lideri, text);
new atext[60];
format(atext, sizeof(atext), "{21DD00}DutyTime: {FFFFFF}%dmin\n", HelperInfo[tesDutyTime]);
strcat(lideri, atext);
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88311) : error 003: declaration of a local variable must appear in a compound block
Daj mi cijelu cmd tu
YCMD:staff(playerid, params[], help)
new text[60];
format(text, sizeof(text), "{AA3333}Offline (%dh)", HelperInfo[tesNeakt]);
strcat(lideri, text);
format(text, sizeof(text), "{21DD00}DutyTime: {FFFFFF}%dmin\n", HelperInfo[tesDutyTime]);
strcat(lideri, text);
YCMD:staff(playerid, params[], help)
{
new text[60];
format(text, sizeof(text), "{AA3333}Offline (%dh)", HelperInfo[tesNeakt]);
strcat(lideri, text);
new atext[60];
format(atext, sizeof(atext), "{21DD00}DutyTime: {FFFFFF}%Admin\n", HelperInfo[tesDutyTime]);
strcat(lideri, atext);
return 1;
}
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88313) : warning 213: tag mismatch
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88313) : error 032: array index out of bounds (variable "HelperInfo")
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88314) : error 017: undefined symbol "lideri"
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88316) : warning 213: tag mismatch
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88316) : error 032: array index out of bounds (variable "HelperInfo")
C:\Users\Administrator\Desktop\BalkanX\gamemodes\sc_Script.pwn(88317) : error 017: undefined symbol "lideri"
Googlaj malo sad to ti je lagano za rijesiti nemam vremena ja sad moram ici do sutra ako ti niko ne rijesi ja cu...
Ok hvala brt najjaci si
Aj probaj ovako
[pawn]
YCMD:staff(playerid, params[], help)
{
#pragma unused help
new text[60];
format(text, sizeof(text), "{AA3333}Offline (%dh)", HelperInfo[tesNeakt]);
strcat(lideri, text);
new atext[60];
format(atext, sizeof(atext), "{21DD00}DutyTime: {FFFFFF}%Admin\n", HelperInfo[tesDutyTime]);
strcat(lideri, atext);
return 1;
}
[/pawn]
Uspeo sam morao sam da dodam [pawn]new lideri[/pawn] hvala buraz LOCKAM TEMU