[Help] Dialog
#1

pawn Код:
public OnPlayerSelectedMenuRow(playerid,row)//----------------------------What all menus do
{
new Menu:CurrentMenu = GetPlayerMenu(playerid);
if (CurrentMenu == FactionMenu)
{
switch(row)
{
case 0://Pilots
{
    SetSpawnInfo(playerid,0,61,1262.9125,40.6773,14.1392,222.5061,371,1,346,500,0,0);
    SetPlayerInterior(playerid,0);
    SendClientMessage(playerid,COLOR_WHITE,"Start your life as a Fly Boy. Will you become an ace? Or die a discrase?");
}
case 1://Marines
{
    SetSpawnInfo(playerid,0,287,291.2855,2041.9082,17.6406,198.7344,356,1000,348,500,0,0);
    SetPlayerArmour(playerid,100);
    SetPlayerInterior(playerid,0);
    SendClientMessage(playerid,COLOR_WHITE,"Start your life as a Marine. Will you rise the ranks and live the war? Or die as a lowly private.");
}
case 2://Gangs Black
{
    SetSpawnInfo(playerid,0,106,213.1244,-183.4817,1.5781,359.8532,355,1000,0,0,0,0);
    SetPlayerInterior(playerid,0);
    SendClientMessage(playerid,COLOR_WHITE,"Start your life as a gangster. Will you raise to be a true OG' or fall as just another soldier.");
}
case 3://Regular
{
    SetSpawnInfo(playerid,0,101,1290.6151,175.4240,20.4609,65.2012,0,0,0,0,0,0);
    SetPlayerInterior(playerid,0);
    SendClientMessage(playerid,COLOR_WHITE,"Start your journey off as a regular.Will you become a billionare? Or go into debt?");
} //LINE  110

Error:
Код:
C:\Users\Zack Farmer\Desktop\Scripting stuff\OLRP Script\FRP.pwn(111) : error 002: only a single statement (or expression) can follow each "case"
Reply
#2

What have you got after case 3, anything else?
Reply
#3

Nope the closing bracket is the edge of my script
Reply
#4

*bump*
Reply
#5

Indent properly and close your callback properly. I cannot stress enough that you should properly indent your code at all times. Not only is it easier to read, but it's also a lot less error prone.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)