[HELP]Locking a skin - 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: [HELP]Locking a skin (
/showthread.php?tid=366704)
[HELP]Locking a skin -
DopeDog - 07.08.2012
Can someone post here a link of tut who shows how to lock skin on some name
Re: [HELP]Locking a skin -
HyDrAtIc - 07.08.2012
what you mean lock it with password?
Re: [HELP]Locking a skin -
DopeDog - 07.08.2012
No I want to lock on someone's name like cj skin locks on name DopeDog
Re: [HELP]Locking a skin -
HyDrAtIc - 07.08.2012
couldn't understand what you said
Re: [HELP]Locking a skin -
Wesley221 - 07.08.2012
pawn Код:
#include <a_samp>
public OnPlayerRequestSpawn(playerid)
{
if( GetPlayerSkin( playerid ) == CJ SKIN HERE ) // compare the skin you got with the CJ skin
{
new pName[24];
GetPlayerName( playerid, pName, sizeof pName ); // getting player name
if( !strcmp( pName, "Name here", false ) ) // change 'name here' to the name you want to not lock this skin for + comparing your current name with the second name
{
return 1; // allow the player to spawn
}
else // names doent match
{
SendClientMessage( playerid, -1, "Skin is locked. " );
return 0; // dont let the player spawn
}
}
return 1;
}
Re: [HELP]Locking a skin -
DopeDog - 07.08.2012
Thanks
Re: [HELP]Locking a skin -
DopeDog - 07.08.2012
But Errors
Код:
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1384) : error 010: invalid function or declaration
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1387) : error 021: symbol already defined: "GetPlayerName"
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1389) : error 010: invalid function or declaration
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1391) : error 010: invalid function or declaration
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1393) : error 010: invalid function or declaration
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1396) : error 054: unmatched closing brace ("}")
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1396 -- 1400) : error 010: invalid function or declaration
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1396 -- 1404) : warning 219: local variable "pName" shadows a variable at a preceding level
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1470) : warning 219: local variable "pName" shadows a variable at a preceding level
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(1630) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(2458) : warning 219: local variable "pName" shadows a variable at a preceding level
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(2476) : warning 219: local variable "pName" shadows a variable at a preceding level
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(5107) : warning 235: public function lacks forward declaration (symbol "OnPlayerInfoChange")
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(6379) : warning 203: symbol is never used: "SetPlayerHalth"
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(900) : warning 204: symbol is assigned a value that is never used: "behbincoenter"
C:\Users\pc\Desktop\Basic RP Script Scratch FIX\gamemodes\ThugLife.pwn(900 -- 6379) : warning 203: symbol is never used: "pName"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
7 Errors.
Re: [HELP]Locking a skin -
Wesley221 - 07.08.2012
Cant be from the piece of code i gave, it compiled just fine.
Re: [HELP]Locking a skin -
DopeDog - 07.08.2012
Ok I'ma try again