[Pomoc]Adminduty

Započeo Stefan Ristic, Decembar 13, 2014, 19:32:02 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:Moja
Detaljan opis problema:Kada ukucam /adminduty zelim da kad se promeni i boja imena da se promeni i skin.Evo skripta pa ako mozete mi reci gde i sta treba da ubacim.
Dio skripte:YCMD:adminduty(playerid, params[], help)
{
    #pragma unused help
#pragma unused params
    if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"EX:RP | "CRVENA"Moras se ulogovati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] == 0) return SCM(playerid, -1, ""CRVENA"[EX:RP] "BELA"Samo Admini!");
new string[256];
if(AdminDuty[playerid] == 0)
{
    format(string,sizeof(string),""ZUTA"[EX:RP] Admin %s je na duznosti !",GetName(playerid));
SendAdminMessage(-1,string);
AdminDuty[playerid] = 1;
SetPlayerColor(playerid, COLOR_BLACK);
SetPlayerArmour(playerid, 99.0);
g_SetPlayerHealth(playerid, 99.0);
}
else if(AdminDuty[playerid] == 1)
{
SetPlayerArmour(playerid, 0);
g_SetPlayerHealth(playerid, 99.0);
format(string,sizeof(string),""ZUTA"[EX:RP] Admin %s vise nije na duznosti !",GetName(playerid));
SendAdminMessage(-1,string);
SetPlayerColor(playerid, BELA2);
AdminDuty[playerid] = 0;
}
return 1;
}

Neke slike/video za lakse dobivanje pomoci(neobavezno):

SetPlayerSkin(playerid, IDSKINA);

Reci mi koji skin kada je offduty ,a koji kada onduty?



Evo da ti bude jasnije ,ovde ti je kod bez skina
YCMD:adminduty(playerid, params[], help)
{
    #pragma unused help
#pragma unused params
    if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"EX:RP | "CRVENA"Moras se ulogovati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] == 0) return SCM(playerid, -1, ""CRVENA"[EX:RP] "BELA"Samo Admini!");
new string[256];
if(AdminDuty[playerid] == 0)
{
    format(string,sizeof(string),""ZUTA"[EX:RP] Admin %s je na duznosti !",GetName(playerid));
SendAdminMessage(-1,string);
AdminDuty[playerid] = 1;
SetPlayerColor(playerid, COLOR_BLACK);
SetPlayerArmour(playerid, 99.0);
g_SetPlayerHealth(playerid, 99.0);
}
else if(AdminDuty[playerid] == 1)
{
SetPlayerArmour(playerid, 0);
g_SetPlayerHealth(playerid, 99.0);
format(string,sizeof(string),""ZUTA"[EX:RP] Admin %s vise nije na duznosti !",GetName(playerid));
SendAdminMessage(-1,string);
SetPlayerColor(playerid, BELA2);
AdminDuty[playerid] = 0;
}
return 1;
}

A ovde sam postavio skinove pa vidi kako sam uradio da znas za ubuduce :)
YCMD:adminduty(playerid, params[], help)
{
    #pragma unused help
#pragma unused params
    if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,"EX:RP | "CRVENA"Moras se ulogovati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] == 0) return SCM(playerid, -1, ""CRVENA"[EX:RP] "BELA"Samo Admini!");
new string[256];
if(AdminDuty[playerid] == 0)
{
    format(string,sizeof(string),""ZUTA"[EX:RP] Admin %s je na duznosti !",GetName(playerid));
SendAdminMessage(-1,string);
AdminDuty[playerid] = 1;
SetPlayerColor(playerid, COLOR_BLACK);
                SetPlayerSkin(playerid, 294);
SetPlayerArmour(playerid, 99.0);
g_SetPlayerHealth(playerid, 99.0);
}
else if(AdminDuty[playerid] == 1)
{
SetPlayerArmour(playerid, 0);
g_SetPlayerHealth(playerid, 99.0);
                SetPlayerSkin(playerid, 18);
format(string,sizeof(string),""ZUTA"[EX:RP] Admin %s vise nije na duznosti !",GetName(playerid));
SendAdminMessage(-1,string);
SetPlayerColor(playerid, BELA2);
AdminDuty[playerid] = 0;
}
return 1;
}

Vec sam to isto uradio, ali u svakom slucaju hvala vam.Resio moze LOCK!

zasto jednostavno nebi u off duty napravio da mu vrati skin koji je imao prije nego sto je dobio ovaj kad je doso na duty ? ;)