Scripting Help - 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: Scripting Help (
/showthread.php?tid=521627)
Scripting Help -
kirostar - 23.06.2014
How to make this for my admin system?
Код:
if (skinid == 217 && !IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1,"This skin is available for staff members only.");
Re: Scripting Help -
Jacksta21 - 23.06.2014
https://sampforum.blast.hk/showthread.php?tid=507416
Read that for future events.
What are your enums for player data?
Re: Scripting Help -
kirostar - 23.06.2014
pInfo
Re: Scripting Help -
Clad - 23.06.2014
What do you mean here ?
Re: Scripting Help -
Jacksta21 - 23.06.2014
Okay well I assume it's something along the lines of
pawn Код:
if (skinid == 217 && pInfo[playerid][pAdmin] == 0) return SendClientMessage(playerid, -1,"This skin is available for staff members only.");
Change the 0 to whatever admin level you want
Re: Scripting Help -
kirostar - 23.06.2014
@Jacksta21 thx it worked
Re: Scripting Help -
kirostar - 23.06.2014
not working, it workes for all regular players and admins except level 1 because i changed the 0 to 1, so i made the code :
Код:
PlayerInfo[playerid][Admin] != 1)
and not working to regular players and admins it works to admin level 1 only
Re: Scripting Help -
Juvanii - 23.06.2014
Quote:
Originally Posted by kirostar
not working, it workes for all regular players and admins except level 1 because i changed the 0 to 1, so i made the code :
Код:
PlayerInfo[playerid][Admin] != 1)
and not working to regular players and admins it works to admin level 1 only
|
How it only works for admins level 1 while u put unequal ( != 1 ) u must have something wrong in your admin system.
Re: Scripting Help -
kirostar - 23.06.2014
ok i made it (== 1 ) and works to regular players and all admins except level 1
and no i'm doing this for all commands and it worked except this.
Re: Scripting Help -
Juvanii - 23.06.2014
Quote:
Originally Posted by kirostar
ok i made it (== 1 ) and works to regular players and all admins except level 1
and no i'm doing this for all commands and it worked except this.
|
I really don't get what do you want! do you want this skin be only for admins or for regular player ?