if(dialogid == DIALOGTRUCKINGLSDOCK)
{
if(response)
{
if(listitem == 0)
{
ShowPlayerDialog(playerid, DIALOGTRUCKINGLSDOCK+1, DIALOG_STYLE_LIST, "Select Cargo", "Pay n Spray Dillimore - Car Parts - 2800KG - $470\nGas Station Dillimore - Food - 4170KG - $595", "Select", "Cancel");
}
}
return 1;
}
if(dialogid == DIALOGTRUCKINGLSDOCK+1)
{
if(response)
{
if(listitem == 0)
{
DillimorePayNSprayCargo[playerid]=1;
SendClientMessage(playerid, YELLOW, "Cargo selected. Destination: Dillimore Pay n Spray");
}
if(listitem == 1)
{
DillimoreGasStationCargo[playerid]=1;
SendClientMessage(playerid, YELLOW, "Cargo selected. Destination: Dillimore Gas station");
}
}
return 1;
}
|
Can i make it like this:
if DillimoreGasStationCargo[playerid] = set on 1 it does not display the dilimore gasstation cargo in the dialog menu. Thanks in advance |
if(response)
{
switch(listitem)
{
case 0: //DillimorePaynSpray selected
{
ShowPlayerDialog(playerid, DIALOGID, DIALOG_STYLE_LIST, "Select Cargo", "Gas Station Dillimore - Food - 4170KG - $595", "Select", "Cancel");
}
case 1: //DillimoreGasStation selected
{
ShowPlayerDialog(playerid, DIALOGID, DIALOG_STYLE_LIST, "Select Cargo", "Pay n Spray Dillimore - Car Parts - 2800KG - $470", "Select", "Cancel");
}
}
}
return 1;
|
Thank you for your message.
Actually what i mean is, if the player selects case 0. How do i make the script hide case 0 for the player? |