Any Method to make Request Class Disable?
#1

Hi, I think lots of people coding a RolePlay Gamemode want to know that.
Thank you.
Reply
#2

public OnPlayerRequestClass(playerid,classid)
{
return 0;
}
Reply
#3

Quote:
Originally Posted by Sabur
View Post
public OnPlayerRequestClass(playerid,classid)
{
return 0;
}
Returning 0 in this callback will prevent the player from spawning. The player can be forced to spawn when SpawnPlayer is used, however the player will re-enter class selection the next time they die.
Reply
#4

maybe spawn him using SetSpawnInfo and SpawnPlayer?
Reply
#5

Quote:
Originally Posted by Sabur
View Post
maybe spawn him using SetSpawnInfo and SpawnPlayer?
I mean....

When people connected to server, they dont display Class Select Window.
Reply
#6

Code:
 
public OnPlayerRequestClass(playerid)
{
   SpawnPlayer(playerid);
   return 1;
}
Reply
#7

pawn Code:
public OnPlayerRequestClass(playerid, classid)
{
    SetSpawnInfo(playerid, 0, 0, 0, 0, 3, 0, 0, 0, 0, 0, 0, 0);
    TogglePlayerSpectating(playerid, true);
    //Add here what you want to happen.
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)