24.11.2011, 03:16
Hi there guys/gals
ive got this case :
i want to eject the player from the vehicle if 'No' is selected and wondered how i would go about doing so.
i have tried this ' RemovePlayerFromVehicle(playerid); ' which works ok but it makes the player get out of the vehicle before any dialog button has been pressed, it does however stop then from hijacking.
if you need any other code from my script just ask.
thanks guys
ive got this case :
Код:
case DIALOG_VEHICLE_BUY: { new vehicleid = GetPVarInt(playerid, "DialogValue1"); new caption[32], info[256]; format(caption, sizeof(caption), "Vehicle ID %d", vehicleid); format(info, sizeof(info), "This vehicle is for sale ($%d)\nWould you like to buy it?", VehicleValue[vehicleid]); ShowPlayerDialog(playerid, dialogid, DIALOG_STYLE_MSGBOX, caption, info, "Yes", "No"); }
i have tried this ' RemovePlayerFromVehicle(playerid); ' which works ok but it makes the player get out of the vehicle before any dialog button has been pressed, it does however stop then from hijacking.
if you need any other code from my script just ask.
thanks guys