Jump to content

Question

Posted

Am bug la sistemu de masini , dau /lockmycar si nu se intampla nimica .

Cum al pot rezolva ?

Va rog ajutatima.

[pawn]if (strcmp("/lockmycar", cmdtext, true, 10) == 0)

    {

        if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, COLOR_GREY, "You must be in your car for this action");

    if(GetCreatorID(vehicleid)!=0)

    {

if (strmatch(VehicleSystem[GetCreatorID(vehicleid)][owner],Spielername(playerid)))

  {

if(Locked[vehicleid] == 0)

            {

                Locked[vehicleid] = 1;

                VehicleSystem[vehicleid][Lock] = 1;

                for(new i=0; i < MAX_PLAYERS; i++)

    {

        if(i == playerid) continue;

        SetVehicleParamsForPlayer(GetPlayerVehicleID(playerid),i,0,1);

    }

                SendClientMessage(playerid, COLOR_GREY, "You have locked your car!");

                GetPlayerName(playerid, sendername, sizeof(sendername));

                format(string, sizeof(string), "* %s is locking his personal vehicle and puts the key in his pocket.", sendername);

ProxDetector(20.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);

GameTextForPlayer(playerid, "~w~Personal Vehicle ~r~Locked", 5000, 6);

PlayerPlaySound(playerid, 1145, 0.0, 0.0, 0.0);

}

else if(Locked[vehicleid] == 1)

{

SendClientMessage(playerid, COLOR_GREY, "Your car is already locked!");

}

}

else

{

    SendClientMessage(playerid, COLOR_GREY, "This is not you're car");

}

}

return 1;

}[/pawn]

<a href="http://www.game-state.eu/94.60.40.50:7777/"><img src="http://www.game-state.eu/94.60.40.50:7777/n-560x95_FFFFFF_FFFFFF_000000_000000.png" alt="www.Game-State.eu" style="border-style: none;" /></a>

1 answer to this question

Recommended Posts

Posted

Vad ca comanda apeleaza la functia locked nu inteleg de ce nu s-ar putea inchide cred ca problema e din intregul sistem locked, cum l-ai facut? (definit,etc.)

Guest
This topic is now closed to further replies.
×
×
  • Create New...

Important Information

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.