From 8683e0aa56b1219f241170e21b681f0be5488b4d Mon Sep 17 00:00:00 2001 From: lambdatiger Date: Mon, 15 Jan 2024 16:10:01 -0600 Subject: [PATCH] Fixed array of double spaced format errors --- addons/frag/CfgAmmo.hpp | 2 +- addons/frag/XEH_PREP.hpp | 2 +- addons/frag/cfgAmmoFragSpawner.hpp | 2 +- addons/frag/functions/fnc_dev_debugAmmo.sqf | 2 +- addons/frag/functions/fnc_dev_fragCalcDump.sqf | 2 +- addons/frag/functions/fnc_dev_sphereDraw.sqf | 4 ++-- addons/frag/functions/fnc_dev_trackHitBox.sqf | 6 +++--- addons/frag/functions/fnc_doFragTargeted.sqf | 4 ++-- addons/frag/functions/fnc_doSpall.sqf | 6 +++--- addons/frag/functions/fnc_getFragInfo.sqf | 2 +- addons/frag/functions/fnc_getMaterialInfo.sqf | 2 +- addons/frag/functions/fnc_shouldFrag.sqf | 2 +- addons/frag/script_component.hpp | 6 +++--- 13 files changed, 21 insertions(+), 21 deletions(-) diff --git a/addons/frag/CfgAmmo.hpp b/addons/frag/CfgAmmo.hpp index 36b9be58ad..a8db2b0b6f 100644 --- a/addons/frag/CfgAmmo.hpp +++ b/addons/frag/CfgAmmo.hpp @@ -78,7 +78,7 @@ class CfgAmmo { }; class GVAR(large_HD): GVAR(large) { - hit = 28; + hit = 28; indirectHit = 2; indirectHitRange = 0.25; airFriction = QUOTE(BASE_DRAG_HD*0.65); diff --git a/addons/frag/XEH_PREP.hpp b/addons/frag/XEH_PREP.hpp index 9565d3e983..f87756ea13 100644 --- a/addons/frag/XEH_PREP.hpp +++ b/addons/frag/XEH_PREP.hpp @@ -23,4 +23,4 @@ PREP(initBlackList); PREP(initMaterialCache); PREP(initRound); PREP(shouldFrag); -PREP(shouldSpall); \ No newline at end of file +PREP(shouldSpall); diff --git a/addons/frag/cfgAmmoFragSpawner.hpp b/addons/frag/cfgAmmoFragSpawner.hpp index 13e5bbe23c..867766f72c 100644 --- a/addons/frag/cfgAmmoFragSpawner.hpp +++ b/addons/frag/cfgAmmoFragSpawner.hpp @@ -193,7 +193,7 @@ class GVAR(def_small_10_top): GVAR(def_small_10) { triggerSpeedCoef[] = {-1.10, -0.710}; }; /* - * Default frag, spawning small fragments only + * Default frag, spawning small fragments only */ class GVAR(def_small_5): GVAR(spawnbase) { submunitionConeType[] = {"random", 5}; diff --git a/addons/frag/functions/fnc_dev_debugAmmo.sqf b/addons/frag/functions/fnc_dev_debugAmmo.sqf index 0047a17950..14c5891a01 100644 --- a/addons/frag/functions/fnc_dev_debugAmmo.sqf +++ b/addons/frag/functions/fnc_dev_debugAmmo.sqf @@ -89,7 +89,7 @@ private _printCount = 0; if (_warn) then { INC(_printCount); if (_csvFormat) then { - 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]; + 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]; diff --git a/addons/frag/functions/fnc_dev_fragCalcDump.sqf b/addons/frag/functions/fnc_dev_fragCalcDump.sqf index 3e0a6972bb..ef92cd9c77 100644 --- a/addons/frag/functions/fnc_dev_fragCalcDump.sqf +++ b/addons/frag/functions/fnc_dev_fragCalcDump.sqf @@ -57,5 +57,5 @@ diag_log text "//****************** fragCalcDump Beg ******************//"; _processedCfgAmmos pushBack _ammo; } forEach _allAmmoConfigs; -diag_log text "//****************** fragCalcDump End ******************//"; +diag_log text "//****************** fragCalcDump End ******************//"; diag_log text format ["//********************** printed %1 *********************//", _nPrinted]; diff --git a/addons/frag/functions/fnc_dev_sphereDraw.sqf b/addons/frag/functions/fnc_dev_sphereDraw.sqf index 123c64ba94..5eb8e30b00 100644 --- a/addons/frag/functions/fnc_dev_sphereDraw.sqf +++ b/addons/frag/functions/fnc_dev_sphereDraw.sqf @@ -36,12 +36,12 @@ if (_color select [0,1] != "(") then { case "green": { _color = "(0,0.8,0,0.5)"; }; case "yellow": { _color = "(0.8,0.8,0,0.5)"; }; case "orange": { _color = "(0.8,0.518,0,0.5)"; }; - default { _color = "(0.8,0.8,0,0.5)";}; + default { _color = "(0.8,0.8,0,0.5)";}; }; }; private _colorString = "#(argb,8,8,3)color" + _color; -private _sphere = createVehicle ["Sign_Sphere25cm_F", ASLtoATL _posASL, [], 0, "CAN_COLLIDE"]; +private _sphere = createVehicle ["Sign_Sphere25cm_F", ASLtoATL _posASL, [], 0, "CAN_COLLIDE"]; _sphere setObjectTextureGlobal [0, _colorString]; GVAR(dev_eventSpheres) pushBack _sphere; diff --git a/addons/frag/functions/fnc_dev_trackHitBox.sqf b/addons/frag/functions/fnc_dev_trackHitBox.sqf index ae1a12e9bf..d23776070b 100644 --- a/addons/frag/functions/fnc_dev_trackHitBox.sqf +++ b/addons/frag/functions/fnc_dev_trackHitBox.sqf @@ -24,14 +24,14 @@ if (isNull _object) exitWith {}; // Grab the right hitBox private _box = []; -if (_object isKindOf "CAManBase") then { +if (_object isKindOf "CAManBase") then { if (isNull objectParent _object) then { _box = 0 boundingBox _object; } else { - _box = boundingBoxReal [_object, "Geometry"]; + _box = boundingBoxReal [_object, "Geometry"]; }; } else { - _box = boundingBoxReal [_object, "FireGeometry"]; + _box = boundingBoxReal [_object, "FireGeometry"]; }; _box params ["_lowP","_upP"]; diff --git a/addons/frag/functions/fnc_doFragTargeted.sqf b/addons/frag/functions/fnc_doFragTargeted.sqf index 9143a53c74..17d7d8b8aa 100644 --- a/addons/frag/functions/fnc_doFragTargeted.sqf +++ b/addons/frag/functions/fnc_doFragTargeted.sqf @@ -26,7 +26,7 @@ params [ "_posASL", ["_fragVelocity", 800, [123]], ["_fragRange", 50, [123]], - ["_maxFrags", 20, [123]], + ["_maxFrags", 20, [123]], ["_fragTypes", [], [[]]], ["_modFragCount", 1, [123]], ["_shotParents", [objNull, objNull], [[]], [2]] @@ -87,7 +87,7 @@ private _totalFragCount = 0; default {_crossSectionArea = 0.75;}; }; } else { - private _boxParams = boundingBoxReal [_target, "FireGeometry"]; + private _boxParams = boundingBoxReal [_target, "FireGeometry"]; _boxParams params ["_pointA", "_pointB"]; private _dims = _pointB vectorDiff _pointA; if (_dims#0 * _dims#1 * _dims#2 <= 0.5) then {continue}; diff --git a/addons/frag/functions/fnc_doSpall.sqf b/addons/frag/functions/fnc_doSpall.sqf index 8a65e60e8b..64c040b3ba 100644 --- a/addons/frag/functions/fnc_doSpall.sqf +++ b/addons/frag/functions/fnc_doSpall.sqf @@ -37,9 +37,9 @@ if (CBA_missionTime - GVAR(lastSpallTime) < ACE_FRAG_SPALL_HOLDOFF || private _material = [_surfaceType] call FUNC(getMaterialInfo); if (_material isEqualTo "ground") then { -#ifdef DEBUG_MODE_FULL + #ifdef DEBUG_MODE_FULL systemChat "ground spall"; -#endif + #endif }; // Find spall speed / fragment info @@ -58,7 +58,7 @@ private _velocityChange = vectorMagnitude _lastVelocity - vectorMagnitude _vel; * of sqrt(2)/50 * round caliber * srqt(change in speed). The second term is * explosive * indirect hit, for any explosive contribution */ -private _spallPower = (ACE_FRAG_ROUND_COEF * _caliber * sqrt _velocityChange + _explosive * _indirectHit) * GVAR(spallIntensity); +private _spallPower = (ACE_FRAG_ROUND_COEF * _caliber * sqrt _velocityChange + _explosive * _indirectHit) * GVAR(spallIntensity); TRACE_3("found speed",_velocityChange,_caliber,_spallPower); diff --git a/addons/frag/functions/fnc_getFragInfo.sqf b/addons/frag/functions/fnc_getFragInfo.sqf index f7e6ddf3f4..b76e6e9ed8 100644 --- a/addons/frag/functions/fnc_getFragInfo.sqf +++ b/addons/frag/functions/fnc_getFragInfo.sqf @@ -30,7 +30,7 @@ if (!isNil "_ammoInfo") exitWith {_ammoInfo}; private _fragTypes = []; private _warn = false; if (isArray (configFile >> "cfgAmmo" >> _ammo >> QGVAR(CLASSES))) then { - _fragTypes = getArray (configFile >> "cfgAmmo" >> _ammo >> QGVAR(CLASSES)); + _fragTypes = getArray (configFile >> "cfgAmmo" >> _ammo >> QGVAR(CLASSES)); } else { _warn = true; }; diff --git a/addons/frag/functions/fnc_getMaterialInfo.sqf b/addons/frag/functions/fnc_getMaterialInfo.sqf index d644ded920..54d01cc103 100644 --- a/addons/frag/functions/fnc_getMaterialInfo.sqf +++ b/addons/frag/functions/fnc_getMaterialInfo.sqf @@ -36,7 +36,7 @@ if (isClass (configFile >> "CfgSurfaces" >> _surfType)) then { } else { // Messy way when a surface isn't added to cfgSurfaces private _surfFileText = toLowerANSI preprocessFile _surfType; _surfFileText = _surfFileText regexReplace ["[^a-z0-9]", ""]; - private _idx = ACE_FRAG_SOUNDENVIRON_STR_LEN + (_surfFileText find "soundenviron"); + private _idx = ACE_FRAG_SOUNDENVIRON_STR_LEN + (_surfFileText find "soundenviron"); if (_surfFileText select [_idx, 5] isEqualTo "empty") then { _idx = ACE_FRAG_SOUNDGIT_STR_LEN + (_surfFileText find "soundhit"); }; diff --git a/addons/frag/functions/fnc_shouldFrag.sqf b/addons/frag/functions/fnc_shouldFrag.sqf index 37805be7bb..d957781f10 100644 --- a/addons/frag/functions/fnc_shouldFrag.sqf +++ b/addons/frag/functions/fnc_shouldFrag.sqf @@ -30,7 +30,7 @@ private _explosive = getNumber (configFile >> "cfgAmmo" >> _ammo >> "explosive") private _indirectHit = getNumber (configFile >> "cfgAmmo" >> _ammo >> "indirectHit"); private _indirectRange = getNumber (configFile >> "cfgAmmo" >> _ammo >> "indirectHitRange"); -if (_skip == 1 || (_force == 0 && {_explosive < 0.5 || {_indirectHit < 3 +if (_skip == 1 || (_force == 0 && {_explosive < 0.5 || {_indirectHit < 3 || {_indirectRange < 5 && _indirectHit < _indirectRange}}})) then { TRACE_5("No frag",_ammo,_skip, _explosive, _indirectRange, _indirectHit); _shouldFrag = false; diff --git a/addons/frag/script_component.hpp b/addons/frag/script_component.hpp index a3d571bcac..800a955208 100644 --- a/addons/frag/script_component.hpp +++ b/addons/frag/script_component.hpp @@ -23,11 +23,11 @@ #define ACE_FRAG_SPALL_HOLDOFF 0.25 #define ACE_FRAG_COUNT_MIN 5 #define ACE_FRAG_COUNT_MAX 50 -#define ACE_FRAG_HITPOINTS ["spine1","spine2","spine3","head","leftarm","leftarmroll","leftforearm","rightarm","rightarmroll","rightforearm","pelvis","leftupleg","leftuplegroll","leftlegroll","leftfoot","rightupleg","rightuplegroll","rightleg","rightlegroll","rightfoot"] +#define ACE_FRAG_HITPOINTS ["spine1","spine2","spine3","head","leftarm","leftarmroll","leftforearm","rightarm","rightarmroll","rightforearm","pelvis","leftupleg","leftuplegroll","leftlegroll","leftfoot","rightupleg","rightuplegroll","rightleg","rightlegroll","rightfoot"] #define ACE_FRAG_HITPOINTS_WEIGHTS -// sqrt(2)/50 +// sqrt(2)/50 #define ACE_FRAG_ROUND_COEF 0.02828427 -// half of gravity approx 9.81/2 +// half of gravity approx 9.81/2 #define ACE_FRAG_HALF_GRAVITY_APPROX 4.905 // stop searching at 0.5% chance to hit #define ACE_FRAG_MIN_FRAG_HIT_CHANCE 0.005