Jump to content
RizlaUK

Exploding Vehicles on Respawn

Recommended Posts

Hi,

I'm having a problem on our server at the moment after moving respawn locations around for Jets & Choppers. Sometimes, on respawn, they explode and I don't know why?

Also a second question I have - I've worked on the default vehicle inventory which loads up fine for the initial vehicles but after a respawn they get the default inventory again. Where do I edit the inventory of vehicles that respawn please?

Thanks

Rizla

Share this post


Link to post
Share on other sites

there is a blanck field on the respawnmodule to put code into. it runs on the newly spawned veh. 

when you use force respawn the vehicle is created and gets immediately respawned so the code can run on it.

 

it's also recommended using this method with "delete with no explositon" or what it is called.

 

and sometimes stuff just explodes in arma :P 

Share this post


Link to post
Share on other sites

If you use BIS respawn module like donelsarjo supposed  the code for respawned vehicle will be like this:

if (isServer) then {
clearWeaponCargoGlobal param [0,objNull];
clearMagazineCargoGlobal param [0,objNull];
clearItemCargoGlobal param [0,objNull];

your custom code,,,
};

param [0,objNull] is the new (respawned) vehicle

Share this post


Link to post
Share on other sites

Ok - thanks for the replies.

I'm using the latest Ahoyworld Invade and Annex so whatever respawn that uses is what I will be using. I will test what has been suggested so far when I get back from work tonight.

Thanks again.

Rizla

Share this post


Link to post
Share on other sites

IIRC the file you are looking for in that version is 'functions\fn_vSetup02.sqf'  to modify the loadouts and adjust vehicles with script once they have (re)spawned. 

 

The respawn system is fairly basic but should still be robust   'functions\fn_vMonitor.sqf'.

 

Regarding collisions and explosions on respawn, ensure you don't put vehicles too close together. Ideally they should be able to rotate 360 degrees on the spawn position and not bump into anything. We accounted for rotation by spawning the vehicle off-site, rotating it there and then setting the position. 

 

That said its been a long time so things/methods may have changed.

 

hope that helped

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

×