Jump to content
Sign in to follow this  
frezinator

How to add more GBU and Sidewinders missiles to F-35B jet plane???

Recommended Posts

F-35B jet plane has only two GBU missiles and two Sidewinders missiles. Is there a way that I can add more missiles??

Share this post


Link to post
Share on other sites

You can use addMagazine to, yeah, add magazines to units or vehicles, even if they don't have enough slots left for it.

To add 2 more GBU's to the F35B:

yourVehicle addMagazine "2Rnd_GBU12";

And to add 2 more sidewinders:

yourVehicle addMagazine "2Rnd_Sidewinder_F35";

If you want much more of em, do it in a loop :D

Share this post


Link to post
Share on other sites

If you want unlimited ammo of everything aswell use this:

this addEventHandler ["Fired","this setvehicleammo 1"];

Where "this" is the plane. Edit with the appropriate name of the plane.

Share this post


Link to post
Share on other sites
You can use addMagazine to, yeah, add magazines to units or vehicles, even if they don't have enough slots left for it.

To add 2 more GBU's to the F35B:

yourVehicle addMagazine "2Rnd_GBU12";

And to add 2 more sidewinders:

yourVehicle addMagazine "2Rnd_Sidewinder_F35";

If you want much more of em, do it in a loop :D

if the jet respawns, does the line "yourVehicle addMagazine "2Rnd_GBU12" disappears?

---------- Post added at 01:35 ---------- Previous post was at 01:32 ----------

If you want unlimited ammo of everything aswell use this:

this addEventHandler ["Fired","this setvehicleammo 1"];

Where "this" is the plane. Edit with the appropriate name of the plane.

thnx but I just want to increase the number of missiles not unlimited.

Share this post


Link to post
Share on other sites

Well if your jet is respawned, you have to re-supply it using the code lines I posted above - if you don't do it, your jet will have the default amount of ammo.

Share this post


Link to post
Share on other sites
Well if your jet is respawned, you have to re-supply it using the code lines I posted above - if you don't do it, your jet will have the default amount of ammo.

how do you re-supply it??? or make it loop?

By the way, I like you profile pic, cute and creepy.

Share this post


Link to post
Share on other sites

you could use a "killed" eventhandler on the vehicle. that way every time the vehicle is destroyed it fires the eventhandler and will recall the script. just use a "waituntil" command at beginning of script for vehicle to be present again. no use in re-arming a vehicle that hasn't respawned yet if your using respawn delay on it ;)

Edited by Nimrod_Z

Share this post


Link to post
Share on other sites
you could use a "killed" eventhandler on the vehicle. that way every time the vehicle is destroyed it fires the eventhandler and will recall the script. just use a "waituntil" command at beginning of script for vehicle to be present again. no use in re-arming a vehicle that hasn't respawned yet if your using respawn delay on it ;)

how do you use killed eventhandler??? im not a pro scripter lol sorry T.T

could you show me the steps?

Share this post


Link to post
Share on other sites

yourVehicle addEventHandler ["killed", {
   _vehicle = (_this select 0);

   // Spawn a new one on the exact same spot
   _newVehicle = (typeOf _vehicle) createVehicle (getPosATL _vehicle);

   // Delete the old one
   deleteVehicle _vehicle;

   _newVehicle addMagazine "2Rnd_GBU12";
   // .....
}];

This is one way you could achieve this, but it's not that practical because the vehicle spawns instantly after the other one got "killed", so you have to think of an appropriate way of respawning your vehicle.

Share this post


Link to post
Share on other sites
yourVehicle addEventHandler ["killed", {
   _vehicle = (_this select 0);

   // Spawn a new one on the exact same spot
   _newVehicle = (typeOf _vehicle) createVehicle (getPosATL _vehicle);

   // Delete the old one
   deleteVehicle _vehicle;

   _newVehicle addMagazine "2Rnd_GBU12";
   // .....
}];

This is one way you could achieve this, but it's not that practical because the vehicle spawns instantly after the other one got "killed", so you have to think of an appropriate way of respawning your vehicle.

how do I run this?

Share this post


Link to post
Share on other sites

Well you run it for example in the init-field of your F35B, you just have to replace "yourVehicle" with "this" and voila :D

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
Sign in to follow this  

×