mirror of
https://github.com/acemod/ACE3.git
synced 2024-08-30 18:23:18 +00:00
Working updating all previously unused/undefined vanilla round definitions
This commit is contained in:
parent
3d3fb434a7
commit
2805699c0c
@ -1,8 +1,65 @@
|
||||
// ~~~~ Autocannons
|
||||
class B_19mm_HE: BulletBase {
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
class B_20mm: BulletBase {
|
||||
// Used in Weisel/AWC Nyx, which makes it a Rheinmetall Mk 20 Rh-202
|
||||
// http://www.navweaps.com/Weapons/WNGER_20mm-65_mk20.php
|
||||
// total mass of 134g probably not enough to do anything
|
||||
/*GVAR(fragCount) = 20;
|
||||
GVAR(metal) = ;
|
||||
GVAR(charge) = ;
|
||||
GVAR(gurney_c) = ;
|
||||
GVAR(gurney_k) = "1/2";*/
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
class B_30mm_HE: B_19mm {
|
||||
// Used in Gorgon (Pandur II), assuming it's a L21A1 RARDEN, specifically HEI-T due to tracers
|
||||
// https://ordtech-industries.com/30x170-mm-ammunition-for-cannons-oerlikon-kcb-hispano-hs831l-l21-rarden/
|
||||
GVAR(skip) = 0;
|
||||
GVAR(classes)[] = {QGVAR(tiny), QGVAR(small)};
|
||||
GVAR(fragCount) = 100;
|
||||
GVAR(metal) = 320;
|
||||
GVAR(charge) = 25;
|
||||
GVAR(gurney_c) = 2547; // Hexal det. velocity / 3
|
||||
GVAR(gurney_k) = "1/2";
|
||||
};
|
||||
class B_30mm_MP: B_30mm_HE {
|
||||
// Used in Mora (FV510 Warrior), assuming it's a Mk44 Bushmaster II, specifically HEI-T due to tracers
|
||||
// http://www.navweaps.com/Weapons/WNUS_30mm_BushmasterII.php
|
||||
GVAR(classes)[] = {QGVAR(tiny), QGVAR(small)};
|
||||
GVAR(fragCount) = 100; // assumed based on https://www.youtube.com/watch?v=c5SsspD0MeU
|
||||
GVAR(metal) = 388;
|
||||
GVAR(charge) = 56;
|
||||
GVAR(gurney_c) = 2600; // guessed
|
||||
GVAR(gurney_k) = "1/2";
|
||||
};
|
||||
class B_40mm_GPR: B_30mm_HE {
|
||||
// Based on noted 40mm Autocannons, base ROF, and ammo names, looks to be a CTAS40, specifically GPR-PD-T
|
||||
// https://www.cta-international.com/ammunition/
|
||||
// https://ndiastorage.blob.core.usgovcloudapi.net/ndia/2002/gun/leslie.pdf
|
||||
GVAR(classes)[] = {QGVAR(tiny), QGVAR(small)};
|
||||
GVAR(fragCount) = 250;
|
||||
GVAR(metal) = 750;
|
||||
GVAR(charge) = 120;
|
||||
GVAR(gurney_c) = 2700; // guessed
|
||||
GVAR(gurney_k) = "1/2";
|
||||
};
|
||||
class B_35mm_AA: BulletBase {
|
||||
// Gepard uses an Oerlikon GDF and the AA vehicles mimics it like it
|
||||
// https://en.wikipedia.org/wiki/Oerlikon_GDF#Ammunition
|
||||
// https://www.nammo.com/product/our-products/ammunition/medium-caliber-ammunition/35-mm-series/35-mm-x-228-hei-sd-and-hei-t-sd/
|
||||
GVAR(skip) = 0;
|
||||
GVAR(classes)[] = {QGVAR(tiny), QGVAR(tiny), QGVAR(small)};
|
||||
GVAR(fragCount) = 175;
|
||||
GVAR(metal) = 400;
|
||||
GVAR(charge) = 98;
|
||||
GVAR(gurney_c) = 2700;
|
||||
GVAR(gurney_k) = "1/2";
|
||||
};
|
||||
|
||||
// ~~~~ Bombs:
|
||||
class Bo_GBU12_LGB: ammo_Bomb_LaserGuidedBase {
|
||||
GVAR(enabled) = 1;
|
||||
|
||||
GVAR(classes)[] = {QGVAR(large), QGVAR(large), QGVAR(large_HD), QGVAR(large), QGVAR(huge), QGVAR(huge_HD), QGVAR(huge)};
|
||||
GVAR(fragCount) = 17500;
|
||||
GVAR(metal) = 140000;
|
||||
@ -11,8 +68,6 @@ class Bo_GBU12_LGB: ammo_Bomb_LaserGuidedBase {
|
||||
GVAR(gurney_k) = "1/2";
|
||||
};
|
||||
class Bomb_04_F: ammo_Bomb_LaserGuidedBase {
|
||||
GVAR(enabled) = 1;
|
||||
|
||||
GVAR(classes)[] = {QGVAR(large), QGVAR(large), QGVAR(large), QGVAR(large), QGVAR(huge), QGVAR(huge_HD), QGVAR(huge)};
|
||||
GVAR(fragCount) = 17500;
|
||||
GVAR(metal) = 140000;
|
||||
@ -25,8 +80,6 @@ class BombCore;
|
||||
class Bo_Mk82: BombCore {
|
||||
ACE_FRAG_ADD_EH;
|
||||
|
||||
GVAR(enabled) = 1;
|
||||
|
||||
GVAR(classes)[] = {QGVAR(large), QGVAR(large), QGVAR(large_HD), QGVAR(large), QGVAR(huge), QGVAR(huge_HD), QGVAR(huge)};
|
||||
GVAR(fragCount) = 17500;
|
||||
GVAR(metal) = 140000;
|
||||
@ -37,11 +90,12 @@ class Bo_Mk82: BombCore {
|
||||
|
||||
// ~~~~ Grenades:
|
||||
class Grenade;
|
||||
class ACE_FlashlightProxy_White: Grenade {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
class GrenadeHand: Grenade {
|
||||
ACE_FRAG_ADD_EH;
|
||||
|
||||
GVAR(enabled) = 1;
|
||||
|
||||
GVAR(skip) = 0;
|
||||
GVAR(force) = 1;
|
||||
/*
|
||||
@ -56,14 +110,15 @@ class GrenadeHand: Grenade {
|
||||
GVAR(gurney_k) = "3/5"; // Gurney shape factor, in this case a sphere. See: http://en.wikipedia.org/wiki/Gurney_equations
|
||||
};
|
||||
class GrenadeHand_stone: GrenadeHand {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
class SmokeShell: GrenadeHand {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
class G_40mm_HE: GrenadeBase {
|
||||
// Source: http://www.inetres.com/gp/military/infantry/grenade/40mm_ammo.html#M441
|
||||
GVAR(enabled) = 1;
|
||||
GVAR(force) = 1;
|
||||
|
||||
GVAR(classes)[] = {QGVAR(small)};
|
||||
@ -75,8 +130,6 @@ class G_40mm_HE: GrenadeBase {
|
||||
};
|
||||
class G_40mm_HEDP: G_40mm_HE {
|
||||
// Source: http://www.inetres.com/gp/military/infantry/grenade/40mm_ammo.html#M433
|
||||
GVAR(enabled) = 1;
|
||||
|
||||
GVAR(classes)[] = {QGVAR(small_HD)};
|
||||
GVAR(fragCount) = 270; // seems to have greater framentation ability, but lower range per source
|
||||
GVAR(metal) = 200;
|
||||
@ -88,21 +141,64 @@ class G_40mm_HEDP: G_40mm_HE {
|
||||
class ACE_G_40mm_HEDP: G_40mm_HEDP {};
|
||||
class ACE_G_40mm_HE: G_40mm_HE {};
|
||||
class ACE_G_40mm_Practice: ACE_G_40mm_HE {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
GVAR(force) = 0;
|
||||
EGVAR(vehicle_damage,incendiary) = 0;
|
||||
};
|
||||
// What is this even?
|
||||
class ACE_G40mm_HE_VOG25P: G_40mm_HE {
|
||||
GVAR(skip) = 0;
|
||||
GVAR(force) = 1;
|
||||
|
||||
// ~~~~ Mines & UXO
|
||||
class Drone_explosive_ammo: MineBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class APERSMine_Range_Ammo;
|
||||
class UXO1_Ammo_Base_F: APERSMine_Range_Ammo {
|
||||
// https://www.globalsecurity.org/military/systems/munitions/blu-97.htm
|
||||
// https://military-history.fandom.com/wiki/BLU-97/B_Combined_Effects_Bomb
|
||||
GVAR(force) = 0;
|
||||
GVAR(classes)[] = {QGVAR(small), QGVAR(small), QGVAR(medium)};
|
||||
GVAR(fragCount) = 300;
|
||||
GVAR(metal) = 1253;
|
||||
GVAR(charge) = 287;
|
||||
GVAR(gurney_c) = 2900;
|
||||
GVAR(gurney_k) = "1/2";
|
||||
|
||||
};
|
||||
class APERSMineDispenser_Mine_Ammo: APERSMine_Range_Ammo {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class UXO_deploy_base_f: SubmunitionBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class ClaymoreDirectionalMine_Remote_Ammo: DirectionalBombBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class SatchelCharge_Remote_Ammo: PipeBombBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class DemoCharge_Remote_Ammo: PipeBombBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class BombDemine_01_Ammo_F: BombCore {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
// ~~~~ RPGs:
|
||||
class R_PG32V_F;
|
||||
class R_TBG32V_F: R_PG32V_F { // Thermobaric
|
||||
GVAR(enabled) = 1;
|
||||
GVAR(fragCount) = 200;
|
||||
GVAR(metal) = 400;
|
||||
GVAR(charge) = 210;
|
||||
@ -205,7 +301,28 @@ class Missile_AA_04_F: MissileBase {
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
// curator ammo entries
|
||||
// Based on Metis-M missiles
|
||||
class M_Vorona_HEAT: MissileBase {
|
||||
// tandem shaped charges
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
class M_Vorona_HE: M_Vorona_HEAT {
|
||||
// All signs point to this being a thermobaric round so low frag count
|
||||
GVAR(skip) = 0;
|
||||
GVAR(fragCount) = 200;
|
||||
GVAR(metal) = 13800;
|
||||
GVAR(charge) = 4950;
|
||||
GVAR(gurney_c) = 2800;
|
||||
GVAR(gurney_k) = "1/2";
|
||||
GVAR(classes)[] = {QGVAR(tiny)};
|
||||
};
|
||||
|
||||
class M_NLAW_AT_F: MissileBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
/// ~~~~ Shell
|
||||
class Sh_125mm_HEAT;
|
||||
class Sh_155mm_AMOS: ShellBase {
|
||||
// Source: http://www.globalsecurity.org/military/systems/munitions/m795.htm
|
||||
@ -276,8 +393,28 @@ class ModuleOrdnanceHowitzer_F_ammo: Sh_155mm_AMOS {
|
||||
GVAR(gurney_c) = 2320;
|
||||
GVAR(gurney_k) = "1/2";
|
||||
};
|
||||
class ammo_Penetrator_Base: ShellBase {
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
// Special
|
||||
class Default;
|
||||
class Laserbeam: Default {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class FuelExplosion: Default {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class HelicopterExploSmall: ShellBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
||||
|
||||
class LightningBolt: ShellBase {
|
||||
ACE_FRAG_RM_EH;
|
||||
GVAR(skip) = 1;
|
||||
};
|
@ -3,11 +3,13 @@
|
||||
/*
|
||||
* Author: ACE-Team, Lambda.Tiger
|
||||
* This function will dump every ammo config that would generate ace_frag
|
||||
* fragements that doesn't have
|
||||
* fragements that could be fired from a weapon
|
||||
*
|
||||
* Arguments:
|
||||
* 0: Log ammo types that wouldn't normall frag
|
||||
* 1: Force a CSV format
|
||||
* 1: Only export ammo classes of classes referenced in cfgAmmo
|
||||
* and their submunitions.
|
||||
* 2: Force a CSV format
|
||||
*
|
||||
* Return Value:
|
||||
* None
|
||||
@ -17,32 +19,54 @@
|
||||
*
|
||||
* Public: No
|
||||
*/
|
||||
|
||||
params [
|
||||
["_debugForce", false, [false]],
|
||||
["_onlyShotAmmoTypes", false, [false]],
|
||||
["_csvFormat", false, [false]]
|
||||
];
|
||||
|
||||
diag_log text format ["~~~~~~~~~~~~~Start [%1]~~~~~~~~~~~~~", _this];
|
||||
|
||||
private _allAmmoConfigs = configProperties [configFile >> "cfgAmmo", "isClass _x && !('ace_frag' in configName _x)", true];
|
||||
private _processedCfgAmmos = [];
|
||||
|
||||
if (_csvFormat) then {
|
||||
diag_log text format ["ammo,gurney_c,gurney_m,gurney_k,gurney_gC,_fragTypes,_fragCount"];
|
||||
diag_log text format ["ammo,gurney_c,gurney_m,gurney_k,gurney_gC,fragTypes,fragCount,Inheritance"];
|
||||
};
|
||||
|
||||
private _printCount = 0;
|
||||
private _allAmmoConfigs = [];
|
||||
if (_onlyShotAmmoTypes) then {
|
||||
private _searchFunc = {
|
||||
params [
|
||||
["_ammo", "", [""]]
|
||||
];
|
||||
if (_ammo isEqualTo "" || {_ammo in _allAmmoConfigs}) exitWith {};
|
||||
_allAmmoConfigs pushBack _ammo;
|
||||
private _subMunit = toLower getText (configFile >> "cfgAmmo" >> _ammo >> "submunitionAmmo");
|
||||
if (_subMunit isNotEqualTo "") then {
|
||||
_subMunit = getArray (configFile >> "cfgAmmo" >> _ammo >> "submunitionAmmo");
|
||||
for "_i" from 0 to count _subMunit - 1 do {
|
||||
if (_i mod 2 == 0) then {
|
||||
[toLower (_subMunit#_i)] call _searchFunc;
|
||||
};
|
||||
};
|
||||
} else {
|
||||
[toLower _subMunit] call _searchFunc;
|
||||
};
|
||||
};
|
||||
private _allMagazineConfigs = configProperties [configFile >> "cfgMagazines", "isClass _x", true];
|
||||
|
||||
{
|
||||
[toLower getText (_x >> "ammo")] call _searchFunc;
|
||||
} forEach _allMagazineConfigs;
|
||||
} else {
|
||||
_allAmmoConfigs = configProperties [configFile >> "cfgAmmo", "isClass _x && !('ace_frag' in configName _x)", true] apply {configName _x};
|
||||
};
|
||||
|
||||
private _processedCfgAmmos = [];
|
||||
private _printCount = 0;
|
||||
{
|
||||
private _ammo = tolower configName _x;
|
||||
private _ammo = _x;
|
||||
if (_ammo != "" && {!(_ammo in _processedCfgAmmos)}) then {
|
||||
_processedCfgAmmos pushBack _ammo;
|
||||
|
||||
//Ignore mines/bombs
|
||||
//if (_ammo isKindOf "TimeBombCore") exitWith {};
|
||||
|
||||
private _ammoConfig = _x;
|
||||
private _ammoConfig = (configFile >> "cfgAmmo" >> _ammo);
|
||||
private _shoulFrag = [_ammo] call FUNC(shouldFrag);
|
||||
|
||||
if (_shoulFrag || _debugForce) then {
|
||||
@ -64,7 +88,7 @@ private _printCount = 0;
|
||||
if (_warn) then {
|
||||
INC(_printCount);
|
||||
if (_csvFormat) then {
|
||||
diag_log text format ["%7,%1,%2,%3,%4,%5,%6", _c, _m, _k, _gC, _fragTypes, _fragCount, _ammo];
|
||||
diag_log text format ["%7,%1,%2,%3,%4,%5,%6,%8", _c, _m, _k, _gC, _fragTypes, _fragCount, _ammo, [_ammoConfig, true] call BIS_fnc_returnParents];
|
||||
} else {
|
||||
diag_log text format ["Ammo [%1] MISSING frag configs:", _ammo];
|
||||
diag_log text format [" _c=%1,_m=%2,_k=%3,_gC=%4,_fragTypes=%5,_fragCount=%6", _c, _m, _k, _gC, _fragTypes, _fragCount];
|
||||
@ -75,4 +99,4 @@ private _printCount = 0;
|
||||
} forEach _allAmmoConfigs;
|
||||
|
||||
diag_log text format ["~~~~~~~~~~~~~~End [%1-%2]~~~~~~~~~~~~~~", count _allAmmoConfigs, count _processedCfgAmmos];
|
||||
diag_log text format ["~~~~~~~~~~~~~~Printed: %1~~~~~~~~~~~", _printCount];
|
||||
diag_log text format ["~~~~~~~~~~~~~~Printed: %1~~~~~~~~~~~", _printCount];
|
@ -38,14 +38,20 @@ private _timeSince = CBA_missionTime - GVAR(lastFragTime);
|
||||
if (_ammo isEqualTo "" || {_posASL isEqualTo [0,0,0] || _timeSince < ACE_FRAG_HOLDOFF}) exitWith {
|
||||
TRACE_3("timeExit",_timeSince,CBA_missionTime,GVAR(lastFragTime));
|
||||
};
|
||||
GVAR(lastFragTime) = CBA_missionTime;
|
||||
private _maxFrags = round (linearConversion [0.1, 1.5, _timeSince, ACE_FRAG_COUNT_MIN, ACE_FRAG_COUNT_MAX, true]);
|
||||
private _maxFrags = round linearConversion [0.1, 1.5, _timeSince, ACE_FRAG_COUNT_MIN, ACE_FRAG_COUNT_MAX, true];
|
||||
TRACE_3("",_timeSince,CBA_missionTime,_maxFrags);
|
||||
|
||||
|
||||
private _ammoArr = [_ammo] call FUNC(getFragInfo);
|
||||
_ammoArr params ["_fragRange", "_fragVel", "_fragTypes", "_modFragCount"];
|
||||
|
||||
if (_modFragCount < 10) then {
|
||||
_maxFrags = _modFragCount*4;
|
||||
GVAR(lastFragTime) = CBA_missionTime - 0.1;
|
||||
} else {
|
||||
GVAR(lastFragTime) = CBA_missionTime;
|
||||
};
|
||||
|
||||
private _heightAGL = (ASLToAGL _posASL)#2;
|
||||
if (_heightAGL < 0.25) then {
|
||||
_posASL = _posASL vectorAdd [0, 0, 0.25];
|
||||
|
@ -79,7 +79,7 @@ if (_warn) then {
|
||||
* of spherical fragmentation
|
||||
*/
|
||||
_ammoInfo = [
|
||||
sqrt (_fragCount / (4 * pi * 0.005)),
|
||||
sqrt (_fragCount / (4 * pi * 0.01)),
|
||||
0.8 * _gC * sqrt (_c / (_m + _c * _k)),
|
||||
_fragTypes,
|
||||
_fragCount / 4 / pi
|
||||
|
Loading…
Reference in New Issue
Block a user