21.03.2014, 20:16
I've a problem whit the Lights Params.
This is my code. When i type /v lights does not turn on nothing.
This is my code. When i type /v lights does not turn on nothing.
PHP код:
if(strcmp(tmp,"luci",true) == 0)
{
if(IsPlayerInAnyVehicle(playerid) && GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
new vehicleid = GetPlayerVehicleID(playerid);
new param[7];
GetVehicleParamsEx(vehicleid,param[0],param[1],param[2],param[3],param[4],param[5],param[6]);
if(param[1])
{
SetVehicleParamsEx(vehicleid,param[0],0,param[2],param[3],param[4],param[5],param[6]);
//SendEmote(playerid,"turns the lights in their vehicle off.");
return 1;
}
else
{
SetVehicleParamsEx(vehicleid,param[0],1,param[2],param[3],param[4],param[5],param[6]);
//SendEmote(playerid,"turns the lights in their vehicle on.");
return 1;
}
}