Developer Documentation - SilenceIsFatto/A3-Antistasi-Ultimate GitHub Wiki
Utility Functions
Spawn enemy support at players position
private _type = "CAS"; // CASDIVE, QRF, Etc
private _side = Occupants; // Occupants/Invaders
["CAS", Occupants, "attack", 500, player, getPosATL player, 0.8, 0] call A3A_fnc_createSupport;
Spawn spec ops HQ attack mission (Server Exec)
private _side = Occupants; // Occupants, Invaders
private _marker = ["CSAT_carrier", "NATO_carrier"] select {_side isEqualTo Occupants};
[_side, _marker, 0] spawn A3A_fnc_attackHQ;
Spawn Trader Mission
Spawns a trader mission on a new save
[] remoteExec ["SCRT_fnc_trader_prepareTraderQuest", 2];
Export Crate To Arms Dealer
Grabs all the weapons out of a crate, grabs mags for them, then puts it into a formatted config array for the arms dealer (returns into your clipboard)
[_target, "modPrefix", "categoryPrefix"] call A3U_fnc_exportCrate;
You can also have multiple crates and do this to export them one at a time
//crate 1
this addAction ["copy", {[(_this select 0), "RHS", "Rifles"] call A3U_fnc_exportCrate}];
//crate 2
this addAction ["copy", {[(_this select 0), "RHS", "Sniper Rifles"] call A3U_fnc_exportCrate}];
Export Pylon Loadout For Config
Grabs the current pylon loadout of an air vehicle and exports it for config (returns into your clipboard)
[_target] call A3U_fnc_exportPylons;
Draw cargo seats of vehicles, with index
(doesn't always work with modded vehicles, due to weird setups)
[cursorObject] call A3U_fnc_logisticsGrabSeats;
Logging
["Message", _fncPath] call A3U_fnc_log;
cfgPatches check
["cfgPatchesClass"] call A3U_fnc_hasAddon;
Alternate Syntax
["cfgPatchesClass1", "cfgPatchesClass2"](/SilenceIsFatto/A3-Antistasi-Ultimate/wiki/"cfgPatchesClass1",-"cfgPatchesClass2") call A3U_fnc_hasAddon;
Weight Test
Logs occurence of each value over 10000 iterations
[_values, _weights] call A3U_fnc_weightTest;
Change faction money/hr
Changes faction money and hr (takes effect immediately, UI will not update until next tick)
[0,0] remoteExec ["A3A_fnc_resourcesFIA",2]; //1 param - hq, 2 param - money
Debug Rivals
Sets up the rivals, and reveals their location on the commander menu
[] spawn {
[] remoteExecCall ["SCRT_fnc_rivals_activate", 2];
uiSleep 2;
[10000] call SCRT_fnc_rivals_addProgressToRivalsLocationReveal;
};
Python Stuff
Town Generator
Town Generator is a bundle of 2 python scripts, input.py and sort.py
sort.py does the heavy lifting and doesn't necessarily need to be used directly (input.py imports the sort.py function). input.py can be ran and will prompt you to put in an array provided by A3U_fnc_exportTowns.
After selecting an export type, it will then provide you with a list of towns/population that you can paste into a mapInfo.hpp file.
VSCode Stuff
VSCode arma-dev.json
{
"title": "Antistasi Ultimate",
"name": "A3U",
"author": "Antistasi Ultimate Dev Team",
"website": "",
"version": "0.0.1",
"buildPath": "build",
"privateKey": "",
"serverDirs": [],
"serverUse32bit": false,
"clientDirs": [
"A3A/addons/config_fixes",
"A3A/addons/core",
"A3A/addons/events",
"A3A/addons/garage",
"A3A/addons/gui",
"A3A/addons/hals",
"A3A/addons/jeroen_arsenal",
"A3A/addons/logistics",
"A3A/addons/main_menu",
"A3A/addons/maps",
"A3A/addons/patcom",
"A3A/addons/scrt",
"A3A/addons/ultimate"
],
"clientMods": [],
"ftpConnection": {},
"steamPath": "pathToSteamLibrary"
}