admin duty

Započeo fiu
25. Maj 2020. Zaključano
850
pregleda
9
postova
leoost
4
Shot Caller
25. Maj 2020.
Problem(error/warning): kad ide admin duty i da smo 10 admin svi idemo duty ali samo kod id 0 radi komande da je na duty kod svih pokazuje da mora bidi na duznost, o cemu je problem ?
Dio skripte
: [ pawn ]vaš odgovor[ /pawn ]
Debug iz server_log(ukoliko je u pitanju crashanje servera - crashdetect log): [ code ]vaš odgovor[ /code ]
Slika/video ingame problema(obavezno ako je ingame problem): link slike

new string;
format(string,sizeof(string),"Admin %s je od sada na duznost (/pitaj)", GetName(playerid));
SCMTA(0x7721ff00,string);
aduty = 1;
SetPlayerColor(playerid, 0x1CCE0000);
g_SetPlayerArmour_g(playerid, 99);
g_SetPlayerHealth_g(playerid, 99);
Danisoni
5
Godfather
25. Maj 2020.
Pošalji primjer komande
leoost
4
Shot Caller
26. Maj 2020.
komanda je da se ulogova na panel i kad mu je tacan pw daje mu duty al samo na id 0 na drugi ne why ?
leoost
4
Shot Caller
26. Maj 2020.

CMD:aduznost(playerid, params[])
{
#pragma unused params
if(PLAYER_ENUM == 0) return GRESKA(playerid, "Nemas dozvolu za koriscenje na ovu komandu jer nisi admin !");
new string;
if(aduty == 0)
{
format(string, sizeof(string),"Unesite admin kod za da bi ste se najavili.");
g_SPD(playerid, DIALOG_APANEL1, DIALOG_STYLE_PASSWORD, "Admin Duty", string, "Ulogovaj se","Exit");
}
else if(aduty == 1)
{
format(string,sizeof(string), "Vie ste admin na duznost ukoliko hocete da idite off duty izaberite prekini duznost.");
g_SPD(playerid, DIALOG_APANEL2, DIALOG_STYLE_MSGBOX, "Admin Duty", string, "Prekini duznost","Exit");
}
return 1;
}

		case DIALOG_APANEL1:
{
            if(!response) return 1;
            if(response)
    {
new kod = strval(inputtext);
if(PLAYER_ENUM == kod)
{
new string;
format(string,sizeof(string),"Admin %s je od sada na duznost (/pitaj)", GetName(playerid));
SCMTA(0x7721ff00,string);
aduty = 1;
SetPlayerColor(playerid, 0x1CCE0000);
g_SetPlayerArmour_g(playerid, 99);
g_SetPlayerHealth_g(playerid, 99);
return 1;
}
else return GRESKA(playerid, "Nije tocan admin kod niste se najavili.");
}
}
Danisoni
5
Godfather
26. Maj 2020.
Razumijem to, ali pošalji komandu u kojoj ti piše da nisi na admin dužnosti
leoost
4
Shot Caller
26. Maj 2020.
Slade wrote on May 26, 2020, 5:15 pm:
Razumijem to, ali pošalji komandu u kojoj ti piše da nisi na admin dužnosti

if(aduty == 0) return GRESKA(playerid, "Moras biti admin na duznost da bi koristio tu komandu.");
Bryan123
4
Enforcer
26. Maj 2020.
Daj DIALOG_APANEL1
Teodor
4
Made Man
26. Maj 2020.
Darkic wrote on May 26, 2020, 5:55 pm:
Daj DIALOG_APANEL1


Dao je vec, pogledaj malo

case DIALOG_APANEL1:
{
            if(!response) return 1;
            if(response)
    {
new kod = strval(inputtext);
if(PLAYER_ENUM == kod)
{
new string;
format(string,sizeof(string),"Admin %s je od sada na duznost (/pitaj)", GetName(playerid));
SCMTA(0x7721ff00,string);
aduty = 1;
SetPlayerColor(playerid, 0x1CCE0000);
g_SetPlayerArmour_g(playerid, 99);
g_SetPlayerHealth_g(playerid, 99);
return 1;
}
else return GRESKA(playerid, "Nije tocan admin kod niste se najavili.");
}
}
Speeak
5
Underboss
27. Maj 2020.
Kako si napravio varijablu aduty?

Morate biti prijavljeni da biste odgovorili na ovu temu.

Prijava

© 2026 SmartShark. All rights reserved.

Powered by Momentum|v2026.3.001 Alpha