13.12.2013, 15:38
how can i make dialog appear after we select team
I want somethin like that it should check before if player is spawned then show dialog
I want somethin like that it should check before if player is spawned then show dialog
pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
SetPlayerPos(playerid,268.8589,1882.7103,-30.0938);//The Place postion
SetPlayerFacingAngle(playerid,1.3648);
SetPlayerCameraPos(playerid,268.6997,1888.3927,-29.5313);//Camera Postiion
SetPlayerCameraLookAt(playerid,268.8589,1882.7103,-30.0938);
switch(classid)
{
case 0:
{
gTeam[playerid] = TEAM_RANGERS;
GameTextForPlayer(playerid, "~h~~h~~b~RANGERS", 2500, 5); // Game text
SetPlayerColor(playerid,COLOR_LIGHTBLUE);
SetPlayerSkin(playerid,287);//army skin
if((gTeam[playerid] =TEAM_RANGERS))
{
ShowPlayerDialog(playerid,CLASSELECT, DIALOG_STYLE_LIST, "{FFFFFF}Choose A Class", "Ranger Company{6EF83C}(0 score)\nSniper Company {6EF83C}(1000 score)\nAnti Tank Company{6EF83C}(2500 score)\nPilot Company{6EF83C}(5000 score)","okay","");
}
}
case 1:
{
gTeam[playerid] = TEAM_SPETSNAZ;
GameTextForPlayer(playerid, "~r~SPETSNAZ", 2500, 5); // Game text
SetPlayerColor(playerid,COLOR_RED);
SetPlayerSkin(playerid,285);//swat skin
if((gTeam[playerid] =TEAM_SPETSNAZ))
{
ShowPlayerDialog(playerid,CLASSELECTSPET, DIALOG_STYLE_LIST, "{FFFFFF}Choose A Class", "Conscript{6EF83C}(0 score)\nScout Sniper{6EF83C}(1000 score)\nMaxim Anti Tank Company{6EF83C}(2500 score)\nRed Pilot Company{6EF83C}(5000 score)","okay","");
}
}
}
return 1;
}