- 0
ajutor engine
-
Similar Content
-
- 1 reply
- 212 views
-
- 3 replies
- 113 views
-
- 4 answers
- 220 views
-
- 3 replies
- 95 views
-
Mapping Ajutor
By Ronni,
- 12 replies
- 258 views
-
-
Recently Browsing 0 members
- No registered users viewing this page.
By Ronni,
We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.
Question
Doggy95
Salut sa-mp.ro, am o problema la comanda engine. Cand intru pe server in orice masina as intra o gasesc mereu pornita, daca apasa pe 2 zice ca motorul e pornit, daca mai apas odata zice din nou ca motorul e pornit, nu se poate opriii X_X. Vreau cand intru in orice masina sami zica sa pornesc motorul.
[pawn]if (PRESSED(KEY_LOOK_BEHIND))
{
new engine,lights,alarm,doors,bonnet,boot,objective;
if(IsPlayerInAnyVehicle(playerid))
{
new veh = GetPlayerVehicleID(playerid);
if(veh != INVALID_VEHICLE_ID)
{
if(EngineStatus[playerid] == 0)
{
new string[256];
new sendername[MAX_PLAYER_NAME];
GetPlayerName(playerid, sendername, sizeof(sendername));
GetVehicleParamsEx(veh,engine,lights,alarm,doors,bonnet,boot,objective);
SetVehicleParamsEx(veh,VEHICLE_PARAMS_ON,lights,alarm,doors,bonnet,boot,objective);
EngineStatus[playerid] = 1;
SendClientMessage(playerid, 0xFFFFFFAA, "{FFFFFF}Ai {FF0000}pornit {FFFFFF} motorul!");
format(string, sizeof(string), "* %s a pornit motorul.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
else if(EngineStatus[playerid] == 0)
{
new string[256];
new sendername[MAX_PLAYER_NAME];
GetPlayerName(playerid, sendername, sizeof(sendername));
GetVehicleParamsEx(veh,engine,lights,alarm,doors,bonnet,boot,objective);
SetVehicleParamsEx(veh,VEHICLE_PARAMS_OFF,lights,alarm,doors,bonnet,boot,objective);
EngineStatus[playerid] = 1;
SendClientMessage(playerid, 0xFFFFFFAA, "{FFFFFF}Ai {E31919}oprit {FFFFFF} motorul!");
format(string, sizeof(string), "* %s a oprit motorul.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);[/pawn]
Link to comment
Share on other sites
14 answers to this question
Recommended Posts