AddSiren 0.3.7
#1

Код:
YCMD:createfactioncar(playerid, params[], help) {
	if(help) {
		SendClientMessage(playerid, X11_WHITE, "Creates a faction vehicle");
		return 1;
	}
	new model, faction, c1, c2;
	if(!sscanf(params, "dddd", faction, model, c1, c2)) {
		if(!IsValidFaction(faction)) {
			SendClientMessage(playerid, X11_TOMATO_2, "Invalid Faction!");
			return 1;
		}
		if(model < 400 || model > 611) {
			SendClientMessage(playerid, X11_TOMATO_2, "Invalid Model!");
			return 1;
		}
		new Float:X, Float:Y, Float:Z, Float:A;
		GetPlayerPos(playerid, X, Y, Z);
		GetPlayerFacingAngle(playerid, A);
		createFactionVehicle(faction, model, X, Y, Z, A, c1, c2);
	} else {
		SendClientMessage(playerid, X11_WHITE, "USAGE: /createfactioncar [factionid] [model] [c1] [c2]");
	}
	return 1;
}
How can I add the new addsiren for 0.3.7 under this cmd?
Reply
#2

createvehicle has another parameter at end
Код:
CreateVehicle(modelid, Float:x, Float:y, Float:z, Float:angle, color1, color2, respawn_delay, addsiren=0)
https://sampwiki.blast.hk/wiki/CreateVehicle
Reply
#3

Quote:
Originally Posted by Dusan01
Посмотреть сообщение
createvehicle has another parameter at end
Код:
CreateVehicle(modelid, Float:x, Float:y, Float:z, Float:angle, color1, color2, respawn_delay, addsiren=0)
https://sampwiki.blast.hk/wiki/CreateVehicle
Undefined symbol addsiren
Reply
#4

You don't ACTUALLY put addsiren=0, that's just the format of the function. You either put 0 or 1 (no siren, has siren).
Reply
#5

1 at the end = SIREN ON
PHP код:
CreateVehicle(modelidFloat:xFloat:yFloat:zFloat:anglecolor1color2respawn_delay1
0 at the end = SIREN OFF
PHP код:
CreateVehicle(modelidFloat:xFloat:yFloat:zFloat:anglecolor1color2respawn_delay0
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)