Admin Spawn?
#1

Ey guys
How do I make some Admin spawnplaces?
Greets Geert
Reply
#2

Under OnPlayerSpawn;

Код:
if(IsPlayerAdmin(playerid))
{
SetPlayerPos(playerid,X,Y,Z);
}
return 1;
}
Replace the X,Y,Z though.
Reply
#3

Quote:
Originally Posted by [LSB
Clinz ]
Under OnPlayerSpawn;

Код:
if(IsPlayerAdmin(playerid);
Replace the X,Y,Z though.
I have to correct you
This would give errors

pawn Код:
if(IsPlayerAdmin(playerid))
{
//======== RCON Administrator Spawn
SetPlayerPos(playerid,X,Y,Z);
}
else
{
//======== Normal Spawn
SetPlayerPos(playerid,X,Y,Z);
}
Put this under
OnplayerSpawn
Replace the X, Y and Z with the coordinate
Reply
#4

Quote:
Originally Posted by ►☺◄©ookie►☺◄
pawn Код:
if(IsPlayerAdmin(playerid)
{
SetPlayerPos(playerid,X,Y,Z);
}
return 1;
}
Yours too, you forgot ) at if statement.

pawn Код:
if(IsPlayerAdmin(playerid))
{
  SetPlayerPos(playerid, X, Y, Z);
}
Reply
#5

Don Corelli, post updated
Reply
#6

mkay thanx! and how to make more spawns with that little script? it have to be random
i'm reading books about scripting and i'm learning it but im still a beginner soz
Reply
#7

sorry for double post but it says'

gamemode.pwn(41) : error 017: undefined symbol "playerid"
gamemode.pwn(43) : error 017: undefined symbol "playerid"

what to do
Reply
#8

Sorry, I just looked back at my code and I realised it was totally wrong and I didn't take my time posting, sorry.
Reply
#9

pawn Код:
if(IsPlayerAdmin(playerid))
{
SetPlayerPos(playerid, x, y, z);
SetPlayerInterior(playerid, 0); //Change this, i put it outside.
}
else
{
SetPlayerPos(playerid, x, y, z);
SetPlayerInterior(playerid, 0); //Change this.
}
Quote:
Originally Posted by Feyenoorder
sorry for double post but it says'

gamemode.pwn(41) : error 017: undefined symbol "playerid"
gamemode.pwn(43) : error 017: undefined symbol "playerid"

what to do
Are you sure you're putting it under OnPlayerSpawn?

EDIT: If somehow you are compiling without the correct public for OnPlayerSpawn, here it is:

pawn Код:
public OnPlayerSpawn(playerid)
{
    return 1;
}
Here, just copy-paste this and use it:

pawn Код:
public OnPlayerSpawn(playerid)
{
    if(IsPlayerAdmin(playerid)) //Change this to your servers admin system.
    {
        SetPlayerPos(playerid, x, y, z);
        SetPlayerInterior(playerid, 0); //Change this, i put it outside.
    }
    else
    {
        SetPlayerPos(playerid, x, y, z);
        SetPlayerInterior(playerid, 0); //Change this.
    }
    return 1;
}
Note: you must be logged into RCON to use this.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)