[NEW] Help with Admin Skin script
#1

Hy Im again! I have a problem with Admin Skin at SPAWN! I want to insert a script at an admin of Admin level 1,admlvl 2, admin lvl 3, and admlvl 4 and OWNER spawn to change skin at 294, and give admin at spawn armour 9999 and hp 9999! But JUST WORK Armour and HP! I want to create for me LIKE THIS :

Quote:

public OnPlayerSpawn(playerid)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo[playerid][pAdmin] > 1)
{
SetPlayerSkin(playerid, 294);
SetPlayerArmour(playerid, 9999);
SetPlayerHealth(playerid, 9999);
}
}

But when I add a return 1; to end of the script, when I join to the server or anywone when he loggin the SOUNT is playing all of the playing!! And if a NEW Player join the game the tutorial DIDNT START I dont know WHY!

CAN SOMEBODY HELP ME
Reply
#2

I think you MUST return 1 on player spawn...nvm

pawn Код:
public OnPlayerRequestSpawn(playerid)
{
    if(PlayerInfo[playerid][pAdmin] > 1)
    {
        SetSpawnInfo(playerid, NO_TEAM, 294, X, Y ,Z, R, 0,0,0,0,0,0);
    }
    return 1;
}

public OnPlayerSpawn(playerid)
{
    if(IsPlayerConnected(playerid))
    {
        if(PlayerInfo[playerid][pAdmin] > 1)
        {
            SetPlayerArmour(playerid, 9999);
            SetPlayerHealth(playerid, 9999);
        }
    }
    return 1;
}
Replace X, Y, Z, R (rotation / facing angle) in SetSpawnInfo
Reply
#3

thanks dude
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)