[HELP] Dialog Respone
#2

Your statements are a bit messed up.

PHP код:
CMD:teles(playeridparams[])
{
    if(
GetPlayerState(playerid) == PLAYER_STATE_PASSENGER) return SendClientMessage(playeridCOLOR_RED"ERROR: you need to be the driver of the vehicle or be onfoot to use this command");
    if(
PlayerInfo[playerid][World] == StuntWorldID)
    {
        
ShowPlayerDialog(playeridDIALOG_STUNTTELESDIALOG_STYLE_LIST"Stunt Teleports""/bp\n/boatpark\n/bs\n/bayside\n/xmas(only during xmas)\n/woods\n/superrace\n/loop\n/mc\n/derby\n/sfa\n/lsa\n/lva\n/aa\n/lounge\n/grove\n/skyfall\n/halfpipe""Ok""Cancel");
    }
    else if(
PlayerInfo[playerid][World] == SkillWorldID || PlayerInfo[playerid][World] == DMWorldID)
    {
        
ShowPlayerDialog(playeridDIALOG_DMTELESDIALOG_STYLE_LIST"Death Match Teleports""/dm\n/dms\n/nrgdm\n/boxing2\n/dildodm\n/mgdm\n/warehousedm\n/boxing\n/hilldm\n/roofdm\n/glass\n/desertdm\n/islanddm""Ok""Cancel");
    }
    else 
ShowPlayerDialog(playeridDIALOG_DRIFTTELESDIALOG_STYLE_LIST"Drift Teleports""/drift 1\n/drift 2\n/drift 3\n/drift 4\n/drift 5\n/drift 6\n/drift 7\n/drift 8\n/drift 9\n/drift 10\ndrift 11\n/arch\n/loco\n/lstune\n/sftune\n/lvtune\n/lounge\n/grove""Ok""Cancel");
    return 
1;

and in OnDialogResponse, if the dialogid is one of those 3, check if response is 1 and then teleport them.

PS: SkillWorldID has nothing and I thought it's same as DMing. If not and it's referring to drifting then remove it from that statement and change "else" to "else if(PlayerInfo[playerid][World] == SkillWorldID)
Reply


Messages In This Thread
[HELP] Dialog Respone - by Mordekaiser - 07.06.2015, 11:07
Re: [HELP] Dialog Respone - by Konstantinos - 07.06.2015, 11:14
Re: [HELP] Dialog Respone - by Mordekaiser - 07.06.2015, 11:17
Re: [HELP] Dialog Respone - by Konstantinos - 07.06.2015, 11:20
Re: [HELP] Dialog Respone - by Mordekaiser - 07.06.2015, 11:21

Forum Jump:


Users browsing this thread: 1 Guest(s)