09.10.2011, 18:41
I have created a matrix system for buses, this is what I got:
This works perfectly, but what I need is that it deletes old 3Dtext if that exists (and deletes it only on that vehicle, which player is in). Could anyone help me?
Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[]) { if(dialogid == 1000) { if(response) { if(listitem == 0) { new vehicle_id, Text3D:tabloo; tabloo = Create3DTextLabel("1 Ida-Ranniku",0x66CC00FF,1141.34, -1389.88, 15.06,30.0,0); //Creating the Vehicle vehicle_id = GetPlayerVehicleID(playerid); //Attaching Text Label To Vehicle Attach3DTextLabelToVehicle( tabloo, vehicle_id, 0.0, 0.0, 2.0); SendClientMessage(playerid, 0x66CC00FF, "Tabloo muudetud!" ); } else if(listitem == 1) { new vehicle_id, Text3D:tabloo; tabloo = Create3DTextLabel("1 Ida-Ranniku",0x66CC00FF,1141.34, -1389.88, 15.06,30.0,0); //Creating the Vehicle vehicle_id = GetPlayerVehicleID(playerid); //Attaching Text Label To Vehicle Attach3DTextLabelToVehicle( tabloo, vehicle_id, 0.0, 0.0, 2.0); SendClientMessage(playerid, 0x66CC00FF, "Tabloo muudetud!" ); } } return 1; } return 1; }