Lag cmds && vlock
#1

why does it lags every time i do a cmd?

next thing iz how to make a player unlock vehicle while outside the car?
Код:
CMD:vlock(playerid, params[])
{
    new engine, lights, alarm, doors, bonnet, boot, objective, vehicleid, string[128];
	if(GetPlayerState(playerid) != PLAYER_STATE_DRIVER) return SendClientMessage(playerid, COLOR_GREY, "You are not driving a vehicle.");
	if(vehicleid == 509 || vehicleid == 481 || vehicleid == 510) return SendClientMessage(playerid, COLOR_GREY, "Bicycles have no engine.");
	vehicleid = GetPlayerVehicleID(playerid);
	GetVehicleParamsEx(vehicleid, engine, lights, alarm, doors, bonnet, boot, objective);
	if(!doors)
	{
	    SetVehicleParamsEx(vehicleid, engine, lights, alarm, 1, bonnet, boot, objective);
	    format(string, sizeof(string), "* %s Locked there car doors.", RPN(playerid));
 		SendNearbyMessage(playerid, 15, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
	}
	else
	{
	    SetVehicleParamsEx(vehicleid, engine, lights, alarm, 0, bonnet, boot, objective);
	    format(string, sizeof(string), "* %s Unlocked there doors.", RPN(playerid));
 		SendNearbyMessage(playerid, 15, string, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE, COLOR_PURPLE);
	}
	return 1;
}
Reply


Messages In This Thread
Lag cmds && vlock - by trapstar2020 - 18.09.2012, 03:21
Re: Lag cmds && vlock - by Backwardsman97 - 18.09.2012, 03:36
Re: Lag cmds && vlock - by trapstar2020 - 18.09.2012, 03:43
Re: Lag cmds && vlock - by trapstar2020 - 18.09.2012, 05:14

Forum Jump:


Users browsing this thread: 2 Guest(s)