SA-MP Forums Archive
Addstaticvehicle - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Addstaticvehicle (/showthread.php?tid=568012)



Addstaticvehicle - MrCallum - 18.03.2015

It compiles fine, I go in game and the cars are not there?


Under OnGamemodeinit()
Код:
	SASDVehicles[0] = AddStaticVehicleEx(427, 26.7187, -23.7637, 1.5596, 175.2540, 0, 1, FACTION_RESPAWN);
	SASDVehicles[1] = AddStaticVehicleEx(427, 333.0364, -24.2525, 1.4860, 184.6541, 0, 1, FACTION_RESPAWN);
	SASDVehicles[2] = AddStaticVehicleEx(598, 348.5789,-92.4388,1.3444,265.1503,79,1,FACTION_RESPAWN);
	SASDVehicles[3] = AddStaticVehicleEx(598,349.0481,-97.2920,1.3380,272.6704,79,1,FACTION_RESPAWN);
	SASDVehicles[4] = AddStaticVehicleEx(598,349.6750,-102.5904,1.3274,272.6704,79,1,FACTION_RESPAWN);
	SASDVehicles[5] = AddStaticVehicleEx(598,349.1131,-108.5566,1.2920,278.3104,79,1,FACTION_RESPAWN);
	SASDVehicles[6] = AddStaticVehicleEx(598,350.3085,-113.8451,1.2625,278.3104,79,1,FACTION_RESPAWN);
	SASDVehicles[7] = AddStaticVehicleEx(598,350.5759,-119.0466,1.2726,278.3104,79,1,FACTION_RESPAWN);
	SASDVehicles[8] = AddStaticVehicleEx(598,351.9917,-124.9374,1.3495,278.3104,79,1,FACTION_RESPAWN);
	SASDVehicles[9] = AddStaticVehicleEx(599,373.2795,-71.3399,1.3828,95.6353,79,1,FACTION_RESPAWN);
	SASDVehicles[10] = AddStaticVehicleEx(599,373.3002,-77.0019,1.3828,95.6353,79,1,FACTION_RESPAWN);
	SASDVehicles[11] = AddStaticVehicleEx(599,373.4614,-82.3609,1.3828,95.6353,79,1,FACTION_RESPAWN);
	SASDVehicles[12] = AddStaticVehicleEx(599,372.8754,-86.9073,1.3828,95.6353,79,1,FACTION_RESPAWN);
	SASDVehicles[13] = AddStaticVehicleEx(523,373.2160,-91.0152,1.3828,95.6353,79,1,FACTION_RESPAWN);
	SASDVehicles[14] = AddStaticVehicleEx(523,373.2743,-96.0160,1.3594,95.6353,79,1,FACTION_RESPAWN);

	BHPVehicles[1] = AddStaticVehicleEx(522,1394.7277,369.8300,19.2961,336.7137,0,0,FACTION_RESPAWN);//NRG
	BHPVehicles[2] = AddStaticVehicleEx(522,1396.0461,372.9980,19.3470,339.7532,0,0,FACTION_RESPAWN);//NRG
	BHPVehicles[3] = AddStaticVehicleEx(522,1386.4509,372.1978,19.3947,248.1804,0,0,FACTION_RESPAWN);//BULLET
	BHPVehicles[4] = AddStaticVehicleEx(560,1387.9003,375.2989,19.4404,245.0870,0,0,FACTION_RESPAWN);//SULTAN



Re: Addstaticvehicle - SickAttack - 18.03.2015

What's assigned to "FACTION_RESPAWN"?


Re: Addstaticvehicle - MrCallum - 18.03.2015

#define FACTION_RESPAWN 1800


Re: Addstaticvehicle - SickAttack - 18.03.2015

You're creating the vehicles on a wall, try moving them a bit.

Example:
pawn Код:
AddStaticVehicleEx(427, 1390.8594,378.6945,19.7578,334.4486, 0, 1, 1800);



Re: Addstaticvehicle - MrCallum - 18.03.2015



NOTE: Right click > Open in new tab.


Re: Addstaticvehicle - SickAttack - 18.03.2015

Quote:
Originally Posted by MrCallum
Посмотреть сообщение


NOTE: Right click > Open in new tab.
As I said, they aren't creating because they are bugged in a wall at Blueberry.


Respuesta: Addstaticvehicle - alexus - 18.03.2015

Not all of them are bugged... Are you looking for them at virtual world 0 ? (yes, is a stupid question but discards that possibility)


Re: Respuesta: Addstaticvehicle - SickAttack - 18.03.2015

Quote:
Originally Posted by alexus
Посмотреть сообщение
Not all of them are bugged... Are you looking for them at virtual world 0 ? (yes, is a stupid question but discards that possibility)
Again, change their position. I tested it and once I changed the position of the first car, it showed up.


Respuesta: Addstaticvehicle - alexus - 18.03.2015

He said that the cars aren't there so I assume "none" of them. I've also tested the coordinates and only the first car is bugged. Why can't he see the others?

Try to place debug prints at your code to check the ids of created vehicles. Something as

Код:
printf("SASDVehicles[0] = %d",SASDVehicles[0]);



Re: Addstaticvehicle - DeitY - 18.03.2015

Make command for /gotoposition

type /gotopos 1394.7277 369.8300 19.2961 0

If they do not exsist, it could be limit reached

either tho try

SASDVehicles[0] = AddStaticVehicleEx(427, 26.7187, -23.7637, 1.5596, 175.2540, 5, 1, 0);