public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { new Float: x, Float: y, Float: z, Float: a; GetPlayerPos (playerid, x, y, z); GetPlayerFacingAngle (playerid, a); if (dialogid == 1 && response == 1) { if (IsPlayerInAnyVehicle (playerid)) return SendClientMessage (playerid, 0xafafafAA, "Step out of the vehicle first."); else { switch (listitem) { case 0: { CreateVehicle (598, x, y, z, a, 16, 1, 50000); } case 1: { CreateVehicle (497, x, y, z, a, 16, 1, 50000); } case 2: { CreateVehicle (415, x, y, z, a, -1, -1, 50000); } case 3: { CreateVehicle (541, x, y, z, a, -1, -1, 50000); } case 4: { CreateVehicle (560, x, y, z, a, -1, -1, 50000); } case 5: { CreateVehicle (523, x, y, z, a, 16, 1, 50000); } case 6: { CreateVehicle (599, x, y, z, a, 16, 1, 50000); } case 7: { CreateVehicle (579, x, y, z, a, -1, -1, 50000); } case 8: { CreateVehicle (562, x, y, z, a, -1, -1, 50000); } case 9: { CreateVehicle (402, x, y, z, a, -1, -1, 50000); } case 10: { CreateVehicle (492, x, y, z, a, -1, -1, 50000); } case 11: { CreateVehicle (422, x, y, z, a, -1, -1, 50000); } case 12: { CreateVehicle (554, x, y, z, a, -1, -1, 50000); } case 13: { CreateVehicle (426, x, y, z, a, -1, -1, 50000); } case 14: { CreateVehicle (521, x, y, z, a, -1, -1, 50000); } case 15: { CreateVehicle (480, x, y, z, a, -1, -1, 50000); } case 16: { CreateVehicle (412, x, y, z, a, -1, -1, 50000); } } } } return 1; } |
you need something like veh=createvehicle(......
then setplayerinvehicle(playerid,veh); |