SA-MP Forums Archive
How can I exactly remove the On Player Class Request.. - 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: How can I exactly remove the On Player Class Request.. (/showthread.php?tid=286378)



How can I exactly remove the On Player Class Request.. - Ehab1911 - 28.09.2011

Hello,

I am making an RP gamemode and I want to remove the OnPlayerClassRequest. When a player joins, he directly move to spawn without choosing a skin. Thank you.


Re: How can I exactly remove the On Player Class Request.. - Pharrel - 28.09.2011

pawn Код:
public OnPlayerRequestClass(playerid)
{
SpawnPlayer(playerid);
return 1;
}
if this doesnt work make a timer to spawn the player like a half second...


Re : How can I exactly remove the On Player Class Request.. - Naruto_Emilio - 28.09.2011

pawn Код:
//Delet this callbacks:
public OnPlayerRequestClass(playerid, classid)

//and

public OnPlayerRequestSpawn(playerid)


//and in OnPlayerSpawn, do SetPlayerPos(playerid, x ,y ,z);
Or

//do this:
//OnPlayerRequestClass
//SpawnPlayer(playerid);
//credits to pharel



Re: How can I exactly remove the On Player Class Request.. - SuperViper - 28.09.2011

Wherever the player logs in, put

pawn Код:
SafeLogin(playerid);
at the bottom after all the other code and then if you haven't already, include YSI\y_timers and add in

pawn Код:
Delay:SafeLogin[450, i](playerid) {
    SpawnPlayer(playerid);
    return 1;
}



Re: How can I exactly remove the On Player Class Request.. - sleepysnowflake - 28.09.2011

@TheGuyAboveMe:

You can just do somehow else without Y_timers.

pawn Код:
forward SpawnTheGuy(playerid); // At 'em top.

SetTimerEx("SpawnTheGuy",1000,true,"%i",playerid); // Under OnPlayerRequestClass or such.

public SpawnTheGuy(playerid) // Between 2 public functions :3
{
SpawnPlayer(playerid);
return 1;
}



Re: How can I exactly remove the On Player Class Request.. - Ehab1911 - 28.09.2011

Alright guys, Thanks a lot for this help! I will be testing all your delightful replies .


Re: How can I exactly remove the On Player Class Request.. - sleepysnowflake - 28.09.2011

Tell me if it works and if it does not tell me what the problem is eg. not spawning or such ....

+Rep if works!


Re: How can I exactly remove the On Player Class Request.. - Ehab1911 - 28.09.2011

@Berlovan,

Hello,

Thank you for the script. I am facing a server-running problem with YSI. It says Error: Could not connect to YSI update server <response was 006>.

And Run time error 20:L " Invalid index parameter bad entry point ".

Using 0.3d


Re: How can I exactly remove the On Player Class Request.. - sleepysnowflake - 28.09.2011

Do you use the latest version on YSI ? If not, downdate to 0.3c. That gotta work!


Re : Re: How can I exactly remove the On Player Class Request.. - Naruto_Emilio - 28.09.2011

Quote:
Originally Posted by Berlovan
Посмотреть сообщение
Tell me if it works and if it does not tell me what the problem is eg. not spawning or such ....

+Rep if works!
Dude you will get banned if you don't delet the part of +rep if it works, this is like, ehmm just read rules.