Vice City Multiplayer

General Discussion => Support => Tutorials => Topic started by: NeskWriter on December 29, 2012, 11:37:21 am

Title: How to display playerclass in skinsel mode
Post by: NeskWriter on December 29, 2012, 11:37:21 am
Hey! Today I'll learn you how to make a small script which will display your class in skin selection mode.
you got
public OnPlayerRequestClass(playerid, classid)
[pawn]{
   new team = GetPlayerTeam(playerid);//we made new "team" to get the team which is selected atm by player in Skin Selection mode
   new string[256];//we made new string
   format(string, sizeof(string), "~h~%d team", team);//we set it's format
   GameTextForPlayer(playerid, string);//we sent game text for player
   return 1;
}[/pawn]

It will display game text, for example: 1 TEAM/2 TEAM