Created
January 14, 2016 18:48
-
-
Save jameslkingsley/2f365a195b4203e48dcc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// F3 - Folk ARPS Assign Gear Script - NATO | |
// Credits: Please see the F3 online manual (http://www.ferstaberinde.com/f3/en/) | |
// ==================================================================================== | |
// DEFINE EQUIPMENT TABLES | |
// The blocks of code below identifies equipment for this faction | |
// | |
// Defined loadouts: | |
// co - commander | |
// dc - deputy commander / squad leader | |
// m - medic | |
// ftl - fire team leader | |
// ar - automatic rifleman | |
// aar - assistant automatic rifleman | |
// rat - rifleman (AT) | |
// dm - designated marksman | |
// mmgg - medium mg gunner | |
// mmgag - medium mg assistant | |
// matg - medium AT gunner | |
// matag - medium AT assistant | |
// hmgg - heavy mg gunner (deployable) | |
// hmgag - heavy mg assistant (deployable) | |
// hatg - heavy AT gunner (deployable) | |
// hatag - heavy AT assistant (deployable) | |
// mtrg - mortar gunner (deployable) | |
// mtrag - mortar assistant (deployable) | |
// msamg - medium SAM gunner | |
// msamag - medium SAM assistant gunner | |
// hsamg - heavy SAM gunner (deployable) | |
// hsamag - heavy SAM assistant gunner (deployable) | |
// sn - sniper | |
// sp - spotter (for sniper) | |
// vc - vehicle commander | |
// vg - vehicle gunner | |
// vd - vehicle driver (repair) | |
// pp - air vehicle pilot / co-pilot | |
// pcc - air vehicle co-pilot (repair) / crew chief (repair) | |
// pc - air vehicle crew | |
// eng - engineer (demo) | |
// engm - engineer (mines) | |
// uav - UAV operator" | |
// div - divers | |
// | |
// r - rifleman | |
// car - carabineer | |
// smg - submachinegunner | |
// gren - grenadier | |
// | |
// v_car - car/4x4 | |
// v_tr - truck | |
// v_ifv - ifv | |
// | |
// crate_small - small ammocrate | |
// crate_med - medium ammocrate | |
// crate_large - large ammocrate | |
// | |
// ==================================================================================== | |
_typeofUnit = toLower (_this select 0); // Tidy input for SWITCH/CASE statements, expecting something like : r = Rifleman, co = Commanding Officer, rat = Rifleman (AT) | |
_unit = _this select 1; // expecting name of unit; originally passed by using 'this' in unit init | |
_isMan = _unit isKindOf "CAManBase"; // We check if we're dealing with a soldier or a vehicle | |
this = _unit; | |
switch (_typeofUnit) do | |
{ | |
// LOADOUT: COMMANDER | |
case "co": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this addWeapon "Binocular"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "ItemGPS"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: DEPUTY COMMANDER AND SQUAD LEADER | |
case "dc": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this addWeapon "Binocular"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "ItemGPS"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: MEDIC | |
case "m": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addBackpack "MNP_B_ACU_KB"; | |
for "_i" from 1 to 25 do {this addItemToBackpack "ACE_fieldDressing";}; | |
for "_i" from 1 to 25 do {this addItemToBackpack "ACE_morphine";}; | |
for "_i" from 1 to 10 do {this addItemToBackpack "ACE_epinephrine";}; | |
for "_i" from 1 to 10 do {this addItemToBackpack "ACE_bloodIV_250";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: FIRE TEAM LEADER | |
case "ftl": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this addWeapon "Binocular"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "ItemGPS"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: AUTOMATIC RIFLEMAN | |
case "ar": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "rhs_200rnd_556x45_B_SAW"; | |
this addWeapon "rhs_weap_m249_pip_L_vfg"; | |
for "_i" from 1 to 2 do {this addItemToVest "rhs_200rnd_556x45_B_SAW";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: ASSISTANT AUTOMATIC RIFLEMAN | |
case "aar": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addBackpack "MNP_B_ACU_KB"; | |
for "_i" from 1 to 6 do {this addItemToBackpack "rhs_200rnd_556x45_B_SAW";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: RIFLEMAN (AT) | |
case "rat": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this addWeapon "tf47_at4_HEDP"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: RIFLEMAN | |
case "r": | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "NVGoggles_OPFOR"; | |
}; | |
// LOADOUT: DEFAULT/UNDEFINED (use RIFLEMAN) | |
default | |
{ | |
removeAllWeapons this; | |
removeAllItems this; | |
removeAllAssignedItems this; | |
removeUniform this; | |
removeVest this; | |
removeBackpack this; | |
removeHeadgear this; | |
removeGoggles this; | |
this forceAddUniform "MNP_CombatUniform_Ranger_C"; | |
for "_i" from 1 to 8 do {this addItemToUniform "ACE_fieldDressing";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "ACE_morphine";}; | |
this addItemToUniform "ACE_EarPlugs"; | |
this addItemToUniform "ACE_Flashlight_XL50"; | |
this addItemToUniform "ACE_CableTie"; | |
for "_i" from 1 to 2 do {this addItemToUniform "rhs_mag_an_m8hc";}; | |
for "_i" from 1 to 4 do {this addItemToUniform "rhs_mag_m67";}; | |
this addVest "MNP_Vest_ACU_2"; | |
this addItemToVest "RH_30Rnd_762x35_FMJ"; | |
this addWeapon "RH_hb_b"; | |
for "_i" from 1 to 12 do {this addItemToVest "RH_30Rnd_762x35_FMJ";}; | |
this addHeadgear "MNP_Helmet_ACU"; | |
this addPrimaryWeaponItem "RH_t1"; | |
this linkItem "ItemMap"; | |
this linkItem "ItemCompass"; | |
this linkItem "ItemWatch"; | |
this linkItem "NVGoggles_OPFOR"; | |
_unit selectweapon primaryweapon _unit; | |
if (true) exitwith {player globalchat format ["DEBUG (f\assignGear\f_assignGear_nato.sqf): Unit = %1. Gear template %2 does not exist, used Rifleman instead.",_unit,_typeofunit]}; | |
}; | |
}; | |
_unit selectweapon primaryweapon _unit; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment