Author: Grumpy Old Man
Author Website:

Requirements: No addons required

Version: 1.23

Short description: Allows certain players to modify aircraft loadouts, as well as rearm the pylons and repair/refuel the aircraft.

Date: 2017-05-24 08:34

Comments: (5)


GOM fnc aircraftLoadout

Grumpy Old Man

Works with all addon aircrafts with properly configured pylons
Preset function to save presets and load them, mission/server independent
deleting a preset works only when holding down CTRL to prevent mishaps
Option to set pylon ownership to either gunner or pilot, also works with presets
Change the livery of the aircraft if it's configured for one
Allows certain players to modify aircraft loadouts, as well as rearm the pylons and repair/refuel the aircraft
Can be restricted to work only if fuel/ammo/repair sources are within 50m of the object holding the menu
You can simultaneously only refuel as many aircraft as you have fuel sources
Can sort for compatible weapons or allow to mount all weapons on all pylons
Ability to set reporting, receiving of remote targets and own position
One click to clear all pylons if you changed your mind
Can be operated by a lone pilot or a designated logistics crew
Multiple players can install multiple pylons on the same plane, one pylon at a time
Pylon installation will take some time, depending on mag size (twin cannons or gatlings will install faster than a 12 missile dagr pod)
Rearming with engines on

Installation / Usage:
Unpack the downloaded .rar and check out the demo mission.
Copy the file structure besides init.sqf and mission.sqm into your own mission. Don't forget to back up before overwriting any files!

Make sure you have aircraft placed that are dynamic loadout compatible (especially for missions made pre 1.70!).
The script now by default needs to have at least one ammo source, repair source or fuel source within 50m of the object that is holding the loadout menu.
The respective options will be greyed out otherwise.
This can be changed however. Simply adjust the variables in the first six parameters of GOM_fnc_aircraftLoadoutInit.sqf to your liking, the comments tell you what each variable does.

Open the dialog instantly for a pilot that's inside a jet/chopper:
[vehicle player,"PILOT"] call GOM_fnc_addAircraftLoadout
This way the pilot will only be able to modify the aircraft he's sitting in.

For usage on ammo trucks, flagpoles or rabbits:
[this] call GOM_fnc_addAircraftLoadout
This way any aircraft within 50m of the object can be modified by using the action attached to the object.

Media: has its own Youtube channel where we will cover the Community made releases.
Subscribe to the Youtube channel

Known issues:
Loading a preset can sometimes not refill all ammo, gonna take a look into that.
Should be working fine other than that.
File structure will be redone in 1.3.

Future plans:
Always open to suggestions.

I quickly threw this one together within one afternoon so please bear with me, should work fine so far though.
I just couldn't stand it anymore having to restart the mission every time I wanted to try a different loadout.

(HOTFIX) Renamed the last remaining dialog parent classes, heh.

(HOTFIX) Renamed dialog parents classes to prevent conflicts with other scripts (thanks @sarogahtyp), should fix any further compatibility issues with other scripts/mods

(HOTFIX) Fixed error being unable to use repair/rearm/refuel with resource dependencies disabled (thanks @loopdk)
Changed the description.ext and cfgFunctions part to avoid issues with other scripts that are using this feature
Adjusted startup text info to be more clear if and which fuel/ammo/repair sources are nearby

Added button to select who has control over the pylon (pilot or gunner)
Added customer presets saved individually for each vehicle for every player
-Presets will be saved for each vehicle type, so you can equip multiple aircraft with the same loadout within a few clicks
-Presets will contain the pylon loadout, ammo amount from each pylon, respective pylon owners (pilot, gunner) and the livery of the aircraft
-Presets are stored in profileNamespace, so they'll persist everytime you use this loadout menu, no matter which server you're on
-Delete button is locked by default, can only be used when holding CTRL to prevent mishaps
Added livery option, will change texture if the aircraft has any in the config
Added option to override the pylon compatibility check, yay 120 DAGR wipeout
Added option to make the presence of ammo/fuel/repair supplies necessary, no ammotruck? no fancy weapons!
Added duration to rearming an aircraft, fully rearming an empty 120 DAGR wipeout can take up to 2 minutes
Added duration to repairing an aircraft, default is set to 60s from 0 to 100% health
-repair speed can be adjusted
Added duration to refuelling an aircraft, fillrate is set to 1800l/min as default and will be calculated accordingly (wipeout with 1000l fuel capacity will take 33s to refill to 100%)
-refill rate can be adjusted
-refuelling will abort when the aircraft is not stationary
-you can only simultaneously refuel as much airplanes as you have fuel sources
Fixed 'clear all pylons' button now to properly remove all leftover weapon classes from the aircraft
Fixed 'rearm' button now to properly rearm all weapons, on board cannons, flare/chaff launchers
Adjusted text size
Improved the mission to give a quick 'demo'
Most likely some stuff I forgot

Added compatibility check for magazines and pylons, so you can't add everything on every pylon.
Installing a pylon takes some time.
Added possibility to execute this for one pilot in a stationary aircraft or as an action from an ammo truck or whatever you'd like.
Added options for reporting and receiving of remote targets as well as reporting the aircrafts own position.


Forum topic:
- BI forums

Enable javascript to be able to download from Armaholic please!

Tags: Script,   Support,   Loadout,   Aircraft,   Rearm,   Pylons,   Repair,   Refuel