Command - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Command (
/showthread.php?tid=616830)
Command -
Hunud - 11.09.2016
Hi
Problem is when i type /jetpack they dont give me jetpack i just got message Jetpack spawned but they dont give me jetpack
Код:
YCMD:jetpack(playerid, params[], help)
{
#pragma unused help
#pragma unused params
if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,""SBOJA"[help]: "BELA"Moras se ulogovati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] < 1) return SCM(playerid,-1,""SBOJA"[help]: "BELA"Samo Admini (AL 1+)!");
if(AdminDuty[playerid] == 0) return Error(playerid, " "BELA"Moras biti na A-Duty!");
SCM(playerid, -1, ""SBOJA"[info]: "BELA"Uzeli ste jetpack!");
SetPlayerSpecialAction(playerid, SPECIAL_ACTION_USEJETPACK);
return 1;
}
Re: Command -
Tass007 - 11.09.2016
Using
PHP код:
CMD:jetpack(playerid, params[])
{
//if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,""SBOJA"[help]: "BELA"Moras se ulogovati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] < 1) return SendClientMessage(playerid,-1,"[help]: Samo Admini (AL 1+)!");
//if(AdminDuty[playerid] == 0) return Error(playerid, " "BELA"Moras biti na A-Duty!");
SendClientMessage(playerid, -1, "[info]: Uzeli ste jetpack!");
SetPlayerSpecialAction(playerid, SPECIAL_ACTION_USEJETPACK);
return 1;
}
I can successfully spawn a jetpack.
Try this, It might not fix it; might be something else in your code.
PHP код:
YCMD:jetpack(playerid)
{
if(UlogovanProvera[playerid] == 0) return SCM(playerid,-1,""SBOJA"[help]: "BELA"Moras se ulogovati da bi koristio ovu komandu!");
if(PlayerInfo[playerid][pAdmin] < 1) return SCM(playerid,-1,""SBOJA"[help]: "BELA"Samo Admini (AL 1+)!");
if(AdminDuty[playerid] == 0) return Error(playerid, " "BELA"Moras biti na A-Duty!");
SCM(playerid, -1, ""SBOJA"[info]: "BELA"Uzeli ste jetpack!");
SetPlayerSpecialAction(playerid, SPECIAL_ACTION_USEJETPACK);
return 1;
}