diff --git a/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf b/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf index b3f4053bdd9..fd087a17f4a 100644 --- a/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf +++ b/addons/advanced_ballistics/functions/fnc_diagnoseWeapons.sqf @@ -113,13 +113,6 @@ for "_i" from 0 to (count _cfgWeapons)-1 do { _weaponInitSpeeds pushBack (_abInitialSpeed / _magSpeed); }; } forEach _data; - { - _x params ["_magazineIndex", "_abInitialSpeed", "_magazine", "_weapon"]; - private _magIndex = _magazines find _magazine; - private _magSpeed = _magazineInitSpeeds select _magIndex; - private _wepIndex = _weapons find _weapon; - _wepSpeed = _weaponInitSpeeds select _wepIndex; - } forEach _data; { diag_log text format ["AB_WeaponInitSpeed,%1,%2", _x, _weaponInitSpeeds select _forEachIndex]; } forEach _weapons; diff --git a/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf b/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf index 9c359bf833e..781b903e2ff 100644 --- a/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf +++ b/addons/advanced_ballistics/functions/fnc_handleFirePFH.sqf @@ -15,7 +15,6 @@ * Public: No */ -private _deleted = false; { _y params ["_bullet","_caliber","_bulletTraceVisible"]; diff --git a/addons/advanced_fatigue/functions/fnc_mainLoop.sqf b/addons/advanced_fatigue/functions/fnc_mainLoop.sqf index 2955e9d6ee0..e3d5096e8ed 100644 --- a/addons/advanced_fatigue/functions/fnc_mainLoop.sqf +++ b/addons/advanced_fatigue/functions/fnc_mainLoop.sqf @@ -101,7 +101,7 @@ private _muscleFactor = sqrt _muscleIntegrity; private _ae1PathwayPowerFatigued = GVAR(ae1PathwayPower) * sqrt (GVAR(ae1Reserve) / AE1_MAXRESERVE) * _oxygen * _muscleFactor; private _ae2PathwayPowerFatigued = GVAR(ae2PathwayPower) * sqrt (GVAR(ae2Reserve) / AE2_MAXRESERVE) * _oxygen * _muscleFactor; private _aePathwayPowerFatigued = _ae1PathwayPowerFatigued + _ae2PathwayPowerFatigued; -private _anPathwayPowerFatigued = GVAR(anPathwayPower) * sqrt (GVAR(anReserve) / AN_MAXRESERVE) * _oxygen * _muscleIntegrity; +// private _anPathwayPowerFatigued = GVAR(anPathwayPower) * sqrt (GVAR(anReserve) / AN_MAXRESERVE) * _oxygen * _muscleIntegrity; // not used // Calculate how much power is consumed from each reserve private _ae1Power = _currentWork min _ae1PathwayPowerFatigued; diff --git a/addons/ai/functions/fnc_garrison.sqf b/addons/ai/functions/fnc_garrison.sqf index 042c4fde3cb..5600f5576dd 100644 --- a/addons/ai/functions/fnc_garrison.sqf +++ b/addons/ai/functions/fnc_garrison.sqf @@ -23,7 +23,7 @@ params [["_startingPos",[0,0,0], [[]], 3], ["_buildingTypes", ["Building"], [[]]], ["_unitsArray", [], [[]]], ["_fillingRadius", 50, [0]], ["_fillingType", 0, [0]], ["_topDownFilling", false, [true]], ["_teleport", false, [true]]]; -TRACE_6("fnc_garrison: Start",_startingPos,_buldingTypes,count _unitsArray,_fillingRadius,_fillingTYpe,_topDownFilling); +TRACE_6("fnc_garrison: Start",_startingPos,_buildingTypes,count _unitsArray,_fillingRadius,_fillingTYpe,_topDownFilling); _unitsArray = _unitsArray select {alive _x && {!isPlayer _x}}; private _currentUnitMoveList = missionNamespace getVariable [QGVAR(garrison_unitMoveList), []]; diff --git a/addons/arsenal/functions/fnc_handleLoadoutsSearchbar.sqf b/addons/arsenal/functions/fnc_handleLoadoutsSearchbar.sqf index 56d6c357d5b..10b2945fc47 100644 --- a/addons/arsenal/functions/fnc_handleLoadoutsSearchbar.sqf +++ b/addons/arsenal/functions/fnc_handleLoadoutsSearchbar.sqf @@ -41,8 +41,6 @@ if (_searchString != "") then { _searchString = toLower _searchString; private _loadoutName = ""; - private _loadout = []; - private _currentTab = str GVAR(currentLoadoutsTab); // Go through all items in panel and see if they need to be deleted or not for "_lbIndex" from (lnbSize _contentPanelCtrl select 0) - 1 to 0 step -1 do { diff --git a/addons/arsenal/missions/Arsenal.VR/initPlayerLocal.sqf b/addons/arsenal/missions/Arsenal.VR/initPlayerLocal.sqf index 28e19bba478..0c698b81624 100644 --- a/addons/arsenal/missions/Arsenal.VR/initPlayerLocal.sqf +++ b/addons/arsenal/missions/Arsenal.VR/initPlayerLocal.sqf @@ -101,7 +101,7 @@ if (!isNil "_massDestructionAchieved" && {_massDestructionAchieved isEqualTo 1}) private _allDisabled = true; { - _hitAlive = _x getVariable ["BIS_fnc_VRHitParts_hitalive", []]; + private _hitAlive = _x getVariable ["BIS_fnc_VRHitParts_hitalive", []]; _allDisabled = _allDisabled && ({!_x} count _hitAlive >= 2); sleep 0.1; diff --git a/addons/artillerytables/functions/fnc_calculateElevation.sqf b/addons/artillerytables/functions/fnc_calculateElevation.sqf index 977253eff93..0d129ac03b9 100644 --- a/addons/artillerytables/functions/fnc_calculateElevation.sqf +++ b/addons/artillerytables/functions/fnc_calculateElevation.sqf @@ -32,7 +32,7 @@ params ["_targetDistance", "_targetHeight", "_muzzleVelocity", ["_highArc", true //MK6_82mm_AIR_FRICTION == -0.0001 if (_airFriction != 0) then { - _muzzleVelocity = [_muzzleVelocity, _temperature, _airDensity] call FUNC(calculateMuzzleVelocity); + _muzzleVelocity = [_muzzleVelocity, _temperature] call FUNC(calculateMuzzleVelocity); }; private _maxResults = [_muzzleVelocity, _airFriction] call FUNC(calculateMaxAngle); diff --git a/addons/artillerytables/functions/fnc_calculateMuzzleVelocity.sqf b/addons/artillerytables/functions/fnc_calculateMuzzleVelocity.sqf index 6f00f74c148..a39fd4011b6 100644 --- a/addons/artillerytables/functions/fnc_calculateMuzzleVelocity.sqf +++ b/addons/artillerytables/functions/fnc_calculateMuzzleVelocity.sqf @@ -6,21 +6,19 @@ * Arguments: * 0: Initial Muzzle velocity; meters/second * 1: Temperature; degrees Celsius - * 2: Atmospheric Density; kg/(meters^3) * * Return Value: * Adjusted Muzzle Velocity; Meters * * Example: - * [200, 15, 1.225] call ace_artilleryTables_fnc_calculateMuzzleVelocity + * [200, 15] call ace_artilleryTables_fnc_calculateMuzzleVelocity * * Public: No */ -params ["_muzzleVelocity", "_temperature", "_airDensity"]; +params ["_muzzleVelocity", "_temperature"]; // Calculate air density -private _relativeDensity = _airDensity / 1.225; private _newMuzzleVelocityCoefficient = (((_temperature + 273.13) / 288.13 - 1) / 40 + 1); private _newMuzzleVelocity = _muzzleVelocity * _newMuzzleVelocityCoefficient; diff --git a/addons/artillerytables/functions/fnc_simulateShot.sqf b/addons/artillerytables/functions/fnc_simulateShot.sqf index be747e862ae..d5fe2243558 100644 --- a/addons/artillerytables/functions/fnc_simulateShot.sqf +++ b/addons/artillerytables/functions/fnc_simulateShot.sqf @@ -31,7 +31,7 @@ params ["_angle", "_targetHeight", "_muzzleVelocity", ["_airFriction", 0], ["_cr //MK6_82mm_AIR_FRICTION == -0.0001 if (_airFriction != 0) then { - _muzzleVelocity = [_muzzleVelocity, _temperature, _atmosphericDensity] call FUNC(calculateMuzzleVelocity); + _muzzleVelocity = [_muzzleVelocity, _temperature] call FUNC(calculateMuzzleVelocity); }; private _atmosphericDensityRatio = _atmosphericDensity / 1.225; diff --git a/addons/common/functions/fnc_canGetInPosition.sqf b/addons/common/functions/fnc_canGetInPosition.sqf index 777f3103a5a..066818d351c 100644 --- a/addons/common/functions/fnc_canGetInPosition.sqf +++ b/addons/common/functions/fnc_canGetInPosition.sqf @@ -36,10 +36,10 @@ private _turret = []; private _radius = 0; -private _enemiesInVehicle = false; //Possible Side Restriction -{ - if (side _unit getFriend side _x < 0.6) exitWith {_enemiesInVehicle = true}; -} forEach crew _vehicle; +// private _enemiesInVehicle = false; //Possible Side Restriction +// { +// if (side _unit getFriend side _x < 0.6) exitWith {_enemiesInVehicle = true}; +// } forEach crew _vehicle; private _return = false; switch (_position) do { diff --git a/addons/common/functions/fnc_cbaSettings_loadFromConfig.sqf b/addons/common/functions/fnc_cbaSettings_loadFromConfig.sqf index 57b93c99639..079834803f9 100644 --- a/addons/common/functions/fnc_cbaSettings_loadFromConfig.sqf +++ b/addons/common/functions/fnc_cbaSettings_loadFromConfig.sqf @@ -24,7 +24,7 @@ if (_typeName == "") then { WARNING_1("Setting [%1] Has no typeName",_varName); _typeName = "SCALAR"; }; -TRACE_3("loadFromConfig",_var,_typeName,_config); +TRACE_3("loadFromConfig",_varName,_typeName,_config); private _isClientSettable = (getNumber (_config >> "isClientSettable")) > 0; private _localizedName = getText (_config >> "displayName"); diff --git a/addons/common/functions/fnc_errorMessage.sqf b/addons/common/functions/fnc_errorMessage.sqf index e98a5baf8f9..317f719b27f 100644 --- a/addons/common/functions/fnc_errorMessage.sqf +++ b/addons/common/functions/fnc_errorMessage.sqf @@ -103,7 +103,6 @@ if (!hasInterface) exitWith {}; _ctrlButtonCancel ]; - private _ctrlRscMessageBoxPos = ctrlPosition _ctrlRscMessageBox; private _ctrlRscMessageBoxPosH = _bottomPosY + (_ctrlButtonOKPos select 3); _ctrlRscMessageBox ctrlSetPosition [ diff --git a/addons/common/functions/fnc_getMapGridData.sqf b/addons/common/functions/fnc_getMapGridData.sqf index c6817b5d5b5..212c17df9ed 100644 --- a/addons/common/functions/fnc_getMapGridData.sqf +++ b/addons/common/functions/fnc_getMapGridData.sqf @@ -22,7 +22,7 @@ GVAR(mapGridData) = []; //--- Extract grid values from world config (Borrowed from BIS_fnc_gridToPos) private _cfgGrid = configFile >> "CfgWorlds" >> worldName >> "Grid"; private _offsetX = getNumber (_cfgGrid >> "offsetX"); -private _offsetY = getNumber (_cfgGrid >> "offsetY"); +// private _offsetY = getNumber (_cfgGrid >> "offsetY"); private _zoomMax = 1e38; private _formatX = ""; private _formatY = ""; diff --git a/addons/common/functions/fnc_statusEffect_get.sqf b/addons/common/functions/fnc_statusEffect_get.sqf index bef27fc6e83..e7b2a19b289 100644 --- a/addons/common/functions/fnc_statusEffect_get.sqf +++ b/addons/common/functions/fnc_statusEffect_get.sqf @@ -49,7 +49,7 @@ if (_effectNumber == 0) exitWith { //empty array - false effect //if no change: skip sending publicVar and events private _effectBoolArray = [_effectNumber, count _statusReasons] call FUNC(binarizeNumber); -TRACE_2("bitArray",_statusIndex,_effectBoolArray); +TRACE_1("bitArray",_effectBoolArray); private _activeEffects = []; { diff --git a/addons/common/functions/fnc_watchVariable.sqf b/addons/common/functions/fnc_watchVariable.sqf index fb1f7db671d..d292d78f756 100644 --- a/addons/common/functions/fnc_watchVariable.sqf +++ b/addons/common/functions/fnc_watchVariable.sqf @@ -43,7 +43,7 @@ if (isNull (findDisplay 46)) exitWith { [{!isNull (findDisplay 46)}, {_this call FUNC(watchVariable);}, _this] call CBA_fnc_waitUntilAndExecute; }; -if (_code isEqualTo {}) then {TRACE_1("using title as code",_title); _code = compile _name;}; +if (_code isEqualTo {}) then {TRACE_1("using name as code",_name); _code = compile _name;}; private _trackedDisplay = uiNamespace getVariable [QGVAR(watchVariableUI), displayNull]; if (isNull _trackedDisplay) then { diff --git a/addons/concertina_wire/functions/fnc_dismount.sqf b/addons/concertina_wire/functions/fnc_dismount.sqf index b73deb6cf51..7a344b3801e 100644 --- a/addons/concertina_wire/functions/fnc_dismount.sqf +++ b/addons/concertina_wire/functions/fnc_dismount.sqf @@ -25,7 +25,6 @@ if (uiNamespace getVariable [QEGVAR(interact_menu,cursorMenuOpened),false]) exit }; params ["_wire", "_unit"]; -private _config = (configOf _unit); private _delay = [45, 30] select ([_unit] call EFUNC(common,isEngineer) || {[_unit] call EFUNC(common,isEOD)}); // TODO: Animation? diff --git a/addons/concertina_wire/functions/fnc_vehicleDamage.sqf b/addons/concertina_wire/functions/fnc_vehicleDamage.sqf index b3ebb7f77c1..c123fa38427 100644 --- a/addons/concertina_wire/functions/fnc_vehicleDamage.sqf +++ b/addons/concertina_wire/functions/fnc_vehicleDamage.sqf @@ -36,7 +36,6 @@ if (_mode == -1) exitWith {}; //9.78744 (10) _type = typeOf _wire; -private _anim = _wire animationPhase "wire_2"; private _pos_w = getPos _wire; private _dir_w = getDir _wire; diff --git a/addons/dagr/functions/fnc_outputData.sqf b/addons/dagr/functions/fnc_outputData.sqf index 646f56d1c88..c2b119c7a43 100644 --- a/addons/dagr/functions/fnc_outputData.sqf +++ b/addons/dagr/functions/fnc_outputData.sqf @@ -47,7 +47,7 @@ GVAR(outputPFH) = [{ private _speed = speed (vehicle ACE_player); _speed = floor (_speed * 10) / 10; _speed = abs(_speed); - _dagrspeed = str _speed + "kph"; + private _dagrspeed = str _speed + "kph"; // Elevation private _elevation = getPosASL ACE_player; diff --git a/addons/dagr/functions/fnc_outputWP.sqf b/addons/dagr/functions/fnc_outputWP.sqf index bf25118c9ea..8ede46833bb 100644 --- a/addons/dagr/functions/fnc_outputWP.sqf +++ b/addons/dagr/functions/fnc_outputWP.sqf @@ -61,7 +61,7 @@ GVAR(outputPFH) = [{ default { "000" + str(_yGrid2) }; }; - _dagrGrid2 = _xCoord2 + " " + _yCoord2; + private _dagrGrid2 = _xCoord2 + " " + _yCoord2; // Distance private _WPpos = [_dagrGrid2, true] call EFUNC(common,getMapPosFromGrid); diff --git a/addons/fortify/functions/fnc_deployObject.sqf b/addons/fortify/functions/fnc_deployObject.sqf index f7e9e6dbadc..5854bd8d09b 100644 --- a/addons/fortify/functions/fnc_deployObject.sqf +++ b/addons/fortify/functions/fnc_deployObject.sqf @@ -38,7 +38,6 @@ private _lmb = LLSTRING(confirm); if (_budget > -1) then {_lmb = _lmb + format [" -$%1", _cost];}; private _rmb = localize ELSTRING(Common,Cancel); private _wheel = LLSTRING(rotate); -private _xAxis = localize "str_disp_conf_xaxis"; private _icons = [["alt", localize "str_3den_display3den_entitymenu_movesurface_text"], ["shift", localize "str_disp_conf_xaxis" + " " + _wheel], ["control", localize "str_disp_conf_yaxis" + " " + _wheel]]; [_lmb, _rmb, _wheel, _icons] call EFUNC(interaction,showMouseHint); diff --git a/addons/frag/functions/fnc_dev_trackHitBox.sqf b/addons/frag/functions/fnc_dev_trackHitBox.sqf index 327e45cf0d3..8790b8a8a92 100644 --- a/addons/frag/functions/fnc_dev_trackHitBox.sqf +++ b/addons/frag/functions/fnc_dev_trackHitBox.sqf @@ -53,8 +53,6 @@ if (GVAR(dbgSphere) && _addSphere && {isNull objectParent _object}) then { // create an optimized outline _upperPoint params ["_x1","_y1","_z1"]; _lowerPoint params ["_x2","_y2","_z2"]; -private _p1 = _upperPoint; -private _p7 = _lowerPoint; private _points = [ _upperPoint, [_x1, _y2, _z1], diff --git a/addons/hellfire/functions/fnc_attackProfile.sqf b/addons/hellfire/functions/fnc_attackProfile.sqf index aa457d02fa5..71a35f39c4d 100644 --- a/addons/hellfire/functions/fnc_attackProfile.sqf +++ b/addons/hellfire/functions/fnc_attackProfile.sqf @@ -72,7 +72,7 @@ switch (_attackStage) do { _attackProfileStateParams set [0, STAGE_ATTACK_TERMINAL]; _attackProfileStateParams set [2, [_projectilePos select 2, _seekerTargetPos distance2D _projectilePos]]; - TRACE_2("New Stage: STAGE_ATTACK_TERMINAL",_distanceToTarget2d,_currentHeightOverTarget); + TRACE_2("New Stage: STAGE_ATTACK_TERMINAL",_timeToGo,_angleToTarget); }; }; case STAGE_SEEK_CRUISE: { // Slowly gain altitude while searching for target diff --git a/addons/interaction/functions/fnc_passMagazine.sqf b/addons/interaction/functions/fnc_passMagazine.sqf index 757700ce8ba..fd1913f6be0 100644 --- a/addons/interaction/functions/fnc_passMagazine.sqf +++ b/addons/interaction/functions/fnc_passMagazine.sqf @@ -27,12 +27,10 @@ private _filteredMags = magazinesAmmoFull _player select { //select magazine with most ammo private _magToPass = _filteredMags select 0; -private _magToPassIndex = 0; { _x params ["_className", "_ammoCount"]; if (_ammoCount > (_magToPass select 1)) then { _magToPass = _x; - _magToPassIndex = _forEachIndex; }; } forEach _filteredMags; diff --git a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf index fc6241a451b..c10943cc650 100644 --- a/addons/laser/functions/fnc_seekerFindLaserSpot.sqf +++ b/addons/laser/functions/fnc_seekerFindLaserSpot.sqf @@ -109,7 +109,6 @@ if (_spots isNotEqualTo []) then { private _c = 0; private _buckets = []; private _excludes = []; - private _bucketIndex = 0; // Put close points together into buckets while { count(_spots) != count(_excludes) && _c < (count _spots) } do { diff --git a/addons/laser/functions/fnc_showVehicleHud.sqf b/addons/laser/functions/fnc_showVehicleHud.sqf index 856030bf8cb..2b2aba4b2f7 100644 --- a/addons/laser/functions/fnc_showVehicleHud.sqf +++ b/addons/laser/functions/fnc_showVehicleHud.sqf @@ -101,7 +101,7 @@ GVAR(pfID) = [{ private _defaultAttackProfile = getText (configFile >> "CfgAmmo" >> _ammo >> "ace_missileguidance" >> "defaultAttackProfile"); private _vehicleLockMode = _vehicle getVariable [QEGVAR(missileguidance,attackProfile), _defaultAttackProfile]; - _modeShort = if (_haveLock) then { + private _modeShort = if (_haveLock) then { getText (configFile >> QEGVAR(missileguidance,AttackProfiles) >> _vehicleLockMode >> "nameLocked"); } else { getText (configFile >> QEGVAR(missileguidance,AttackProfiles) >> _vehicleLockMode >> "name"); diff --git a/addons/magazinerepack/functions/fnc_simulateRepackEvents.sqf b/addons/magazinerepack/functions/fnc_simulateRepackEvents.sqf index 6864726e1ef..82e3b20a454 100644 --- a/addons/magazinerepack/functions/fnc_simulateRepackEvents.sqf +++ b/addons/magazinerepack/functions/fnc_simulateRepackEvents.sqf @@ -32,7 +32,6 @@ private _fnc_newMag = { private _lowIndex = 0; private _highIndex = (count _arrayOfAmmoCounts) - 1; -private _ammoToTransfer = 0; private _ammoAvailable = 0; private _time = 0; private _events = []; diff --git a/addons/maptools/functions/fnc_handleMouseButton.sqf b/addons/maptools/functions/fnc_handleMouseButton.sqf index 5c35c699d7d..5a00b1ab1b9 100644 --- a/addons/maptools/functions/fnc_handleMouseButton.sqf +++ b/addons/maptools/functions/fnc_handleMouseButton.sqf @@ -73,8 +73,6 @@ if (_button != 0) exitWith { false // return }; -private _handled = false; - // If releasing if (_dir != 1) then { if (GVAR(mapTool_isDragging) || GVAR(mapTool_isRotating)) then { diff --git a/addons/marker_flags/functions/fnc_pickUpFlag.sqf b/addons/marker_flags/functions/fnc_pickUpFlag.sqf index 661f476fb63..c3484e6eeb4 100644 --- a/addons/marker_flags/functions/fnc_pickUpFlag.sqf +++ b/addons/marker_flags/functions/fnc_pickUpFlag.sqf @@ -19,7 +19,7 @@ params [["_flag", objNull, [objNull]], ["_unit", objNull, [objNull]], ["_args", [""], [[]]]]; _args params ["_item"]; -TRACE_3("pickupFlag",_unit,_flag,_itemName); +TRACE_3("pickupFlag",_unit,_flag,_item); if (isNull _flag) exitWith {}; diff --git a/addons/medical/functions/fnc_addDamageToUnit.sqf b/addons/medical/functions/fnc_addDamageToUnit.sqf index e490399c4bf..2ffe8d77322 100644 --- a/addons/medical/functions/fnc_addDamageToUnit.sqf +++ b/addons/medical/functions/fnc_addDamageToUnit.sqf @@ -32,7 +32,7 @@ params [ "", ["_overrideInvuln", true, [true]] ]; -TRACE_7("addDamageToUnit",_unit,_damageToAdd,_bodyPart,_typeOfDamage,_instigator,_damageSelectionArray,_overrideInvuln); +TRACE_7("addDamageToUnit",_unit,_damageToAdd,_bodyPart,_typeOfDamage,_instigator,nil,_overrideInvuln); _bodyPart = toLowerANSI _bodyPart; private _bodyPartIndex = ALL_BODY_PARTS find _bodyPart; diff --git a/addons/medical_feedback/functions/fnc_effectHeartBeat.sqf b/addons/medical_feedback/functions/fnc_effectHeartBeat.sqf index 89d98883fc7..57e31d80e94 100644 --- a/addons/medical_feedback/functions/fnc_effectHeartBeat.sqf +++ b/addons/medical_feedback/functions/fnc_effectHeartBeat.sqf @@ -16,7 +16,7 @@ */ if (EGVAR(common,OldIsCamera)) exitWith { - TRACE_2("Ending heart beat effect - scripted camera",_heartRate,EGVAR(common,OldIsCamera)); + TRACE_2("Ending heart beat effect - scripted camera",GET_HEART_RATE(ACE_player),EGVAR(common,OldIsCamera)); GVAR(heartBeatEffectRunning) = false; }; diff --git a/addons/medical_treatment/functions/fnc_createLitter.sqf b/addons/medical_treatment/functions/fnc_createLitter.sqf index df9c2e7f4de..8d8c9153931 100644 --- a/addons/medical_treatment/functions/fnc_createLitter.sqf +++ b/addons/medical_treatment/functions/fnc_createLitter.sqf @@ -27,7 +27,6 @@ params ["_medic", "_patient", "_bodyPart", "_classname"]; if (vehicle _medic != _medic || {vehicle _patient != _patient}) exitWith {}; // Determine if treated body part is bleeding -private _index = ALL_BODY_PARTS find toLowerANSI _bodyPart; private _isBleeding = (GET_OPEN_WOUNDS(_patient) get _bodyPart) findIf { _x params ["", "_amountOf", "_bleeding"]; _amountOf * _bleeding > 0 diff --git a/addons/medical_treatment/functions/fnc_medicationLocal.sqf b/addons/medical_treatment/functions/fnc_medicationLocal.sqf index 18ef4e4d680..cb140deaeab 100644 --- a/addons/medical_treatment/functions/fnc_medicationLocal.sqf +++ b/addons/medical_treatment/functions/fnc_medicationLocal.sqf @@ -52,7 +52,7 @@ TRACE_1("Running treatmentMedicationLocal with Advanced configuration for",_pati private _partIndex = ALL_BODY_PARTS find toLowerANSI _bodyPart; if (HAS_TOURNIQUET_APPLIED_ON(_patient,_partIndex)) exitWith { - TRACE_1("unit has tourniquets blocking blood flow on injection site",_tourniquets); + TRACE_1("unit has tourniquets blocking blood flow on injection site",GET_TOURNIQUETS(_patient)); private _occludedMedications = _patient getVariable [QEGVAR(medical,occludedMedications), []]; _occludedMedications pushBack [_partIndex, _classname]; _patient setVariable [QEGVAR(medical,occludedMedications), _occludedMedications, true]; diff --git a/addons/missileguidance/functions/fnc_attackProfile_LIN.sqf b/addons/missileguidance/functions/fnc_attackProfile_LIN.sqf index cc823b1e8c3..40e6f3e667e 100644 --- a/addons/missileguidance/functions/fnc_attackProfile_LIN.sqf +++ b/addons/missileguidance/functions/fnc_attackProfile_LIN.sqf @@ -30,9 +30,6 @@ private _projectilePos = getPosASL _projectile; private _distanceToTarget = _projectilePos vectorDistance _seekerTargetPos; private _distanceToShooter = _projectilePos vectorDistance _shooterPos; -private _distanceShooterToTarget = _shooterPos vectorDistance _seekerTargetPos; - -private _ttgo = _distanceToTarget / (vectorMagnitude velocity _projectile); TRACE_2("",_distanceToTarget,_distanceToShooter); diff --git a/addons/missileguidance/functions/fnc_dev_ProjectileCamera.sqf b/addons/missileguidance/functions/fnc_dev_ProjectileCamera.sqf index bf3a5af67c5..df8c1e92af1 100644 --- a/addons/missileguidance/functions/fnc_dev_ProjectileCamera.sqf +++ b/addons/missileguidance/functions/fnc_dev_ProjectileCamera.sqf @@ -51,8 +51,6 @@ private _displayEH = (findDisplay 46) displayAddEventHandler ["KeyDown", { [_pfh] call CBA_fnc_removePerFrameHandler; }; - private _currentProjectilePos = getPosATLVisual _projectile; - _camera camPrepareTarget _projectile; _camera camPrepareRelPos [0, -5, 1]; _camera camCommitPrepared 0; diff --git a/addons/missileguidance/functions/fnc_javelin_midCourseTransition.sqf b/addons/missileguidance/functions/fnc_javelin_midCourseTransition.sqf index 58995dee31d..a85273023fb 100644 --- a/addons/missileguidance/functions/fnc_javelin_midCourseTransition.sqf +++ b/addons/missileguidance/functions/fnc_javelin_midCourseTransition.sqf @@ -34,7 +34,6 @@ _targetData params ["_targetDirection", "_attackProfileDirection", "_targetRange _attackProfileStateParams params ["_state", "_stableTime", "_target"]; private _projectileDirection = vectorNormalized velocity _projectile; -private _targetDistance = _target vectorDistance getPosASLVisual _projectile; private _targetDirection = (getPosASLVisual _projectile) vectorFromTo _target; private _angle = _projectileDirection vectorCos _targetDirection; if (_angle > cos REQUIRED_ANGLE) then { diff --git a/addons/missileguidance/functions/fnc_onFired.sqf b/addons/missileguidance/functions/fnc_onFired.sqf index 9cc91f300a9..150b2fd5f06 100644 --- a/addons/missileguidance/functions/fnc_onFired.sqf +++ b/addons/missileguidance/functions/fnc_onFired.sqf @@ -126,10 +126,8 @@ private _navigationStateSubclass = _config >> "navigationStates"; private _states = getArray (_navigationStateSubclass >> "states"); private _navigationStateData = []; -private _initialState = ""; if (_states isNotEqualTo []) then { - _initialState = _states select 0; { private _stateClass = _navigationStateSubclass >> _x; _navigationStateData pushBack [ diff --git a/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf b/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf index c3dcc2cfe49..9b982670f3a 100644 --- a/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf +++ b/addons/mk6mortar/functions/fnc_handlePlayerVehicleChanged.sqf @@ -21,9 +21,6 @@ params ["_player", "_newVehicle"]; if (isNull _newVehicle) exitWith {}; if !(_newVehicle isKindOf "Mortar_01_base_F") exitWith {}; -private _tubeWeaponName = (weapons _newVehicle) select 0; -private _fireModes = getArray (configFile >> "CfgWeapons" >> _tubeWeaponName >> "modes"); - // Restore last firemode private _lastSavedWeaponsInfo = _newVehicle getVariable QGVAR(lastFireMode); diff --git a/addons/nightvision/functions/fnc_refreshGoggleType.sqf b/addons/nightvision/functions/fnc_refreshGoggleType.sqf index 2c7dedaa834..5e3aa2125af 100644 --- a/addons/nightvision/functions/fnc_refreshGoggleType.sqf +++ b/addons/nightvision/functions/fnc_refreshGoggleType.sqf @@ -34,7 +34,6 @@ if ((alive ACE_player) && {isNull (ACE_controlledUAV select 0)}) then { // Test if we are using player's nvg or if sourced from vehicle: private _currentVehicle = vehicle ACE_player; - private _vehConfig = configOf _currentVehicle; if (cameraView != "GUNNER") exitWith {true}; // asume hmd usage outside of gunner view if ([ACE_player] call CBA_fnc_canUseWeapon) exitWith {true}; // FFV diff --git a/addons/nlaw/functions/fnc_navigation.sqf b/addons/nlaw/functions/fnc_navigation.sqf index 7572b44d6f3..822c4ee7549 100644 --- a/addons/nlaw/functions/fnc_navigation.sqf +++ b/addons/nlaw/functions/fnc_navigation.sqf @@ -50,23 +50,17 @@ private _yawRate = if (_timestep == 0) then { }; _navigationParams set [3, _currentYaw]; -private _yawModifier = if (_yawChange == 0) then { - 1 -} else { - abs (_yawRate / _yawChange) -}; - private _yawRateDifference = _yawChange - _yawRate; -private _yawChangeDerivative = if (_timestep == 0) then { - 0 -} else { - (_yawRateDifference - _lastYawRateDifference) / _timestep -}; _navigationParams set [6, _yawRateDifference]; private _desiredYawChange = _yawRateDifference * PROPORTIONALITY_CONSTANT + _yawRateDifference * 2; #ifdef DRAW_NLAW_INFO +private _yawModifier = if (_yawChange == 0) then { + 1 +} else { + abs (_yawRate / _yawChange) +}; drawIcon3D ["\a3\ui_f\data\IGUI\Cfg\Cursors\selectover_ca.paa", [1,0,1,1], ASLToAGL getPosASLVisual _projectile, 0.75, 0.75, 0, format ["dP [%1] dY: [%2]", _desiredPitchChange, _desiredYawChange], 1, 0.025, "TahomaB"]; drawIcon3D ["\a3\ui_f\data\IGUI\Cfg\Cursors\selectover_ca.paa", [1,0,1,1], [0, 0, 1] vectorAdd ASLToAGL getPosASLVisual _projectile, 0.75, 0.75, 0, format ["pitch proportional [%1] yaw proportional [%2]", _pitchModifier, _yawModifier], 1, 0.025, "TahomaB"]; #endif @@ -75,4 +69,3 @@ TRACE_4("nlaw pitch/yaw info",_currentPitch,_lastPitch,_currentYaw,_lastYaw); TRACE_6("nlaw navigation",_yawChange,_desiredYawChange,_pitchChange,_desiredPitchChange,_yawRate,_pitchRate); _projectile vectorModelToWorldVisual [_yawChange + _desiredYawChange, 0, _pitchChange + _desiredPitchChange] - diff --git a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf index da87c5fdbaa..6d304ac0c52 100644 --- a/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf +++ b/addons/overheating/functions/fnc_updateSpareBarrelsTemperaturesThread.sqf @@ -21,7 +21,7 @@ TRACE_1("updateSpareBarrelsTemperaturesThread1",GVAR(storedSpareBarrels)); // Calculate cooling private _finalTemp = [_initialTemp, _barrelMass, CBA_missionTime - _initialTime, 0] call FUNC(calculateCooling); //the zero is to indicate an open bolt gun. Barrel is outside of a gun here, so always open. - TRACE_4("updateSpareBarrelsTemperaturesThread2",_barrelMagazineID,_initialTemp,_finalTemp,_barrelMass); + TRACE_4("updateSpareBarrelsTemperaturesThread2",_x,_initialTemp,_finalTemp,_barrelMass); if (_finalTemp <= (ambientTemperature select 0)) then { // The barrel is cool enough to finish calculating. Remove it from the hash GVAR(storedSpareBarrels) deleteAt _x; diff --git a/addons/overpressure/functions/fnc_overpressureDamage.sqf b/addons/overpressure/functions/fnc_overpressureDamage.sqf index f727413d4a5..96e651bb097 100644 --- a/addons/overpressure/functions/fnc_overpressureDamage.sqf +++ b/addons/overpressure/functions/fnc_overpressureDamage.sqf @@ -42,7 +42,7 @@ TRACE_3("cache",_overpressureAngle,_overpressureRange,_overpressureDamage); TRACE_4("Affected:",_x,_axisDistance,_distance,_angle); if (_angle < _overpressureAngle && {_distance < _overpressureRange} && {!lineIntersects _line} && {!terrainIntersectASL _line2}) then { - TRACE_2("",isDamageAllowed _unit,_unit getVariable [ARR_2(QEGVAR(medical,allowDamage),true)]); + TRACE_2("",isDamageAllowed _x,_x getVariable [ARR_2(QEGVAR(medical,allowDamage),true)]); // Skip damage if not allowed if (isDamageAllowed _x && {_x getVariable [QEGVAR(medical,allowDamage), true]}) then { diff --git a/addons/quickmount/functions/fnc_addFreeSeatsActions.sqf b/addons/quickmount/functions/fnc_addFreeSeatsActions.sqf index efb40d2ac1a..4dd196455f2 100644 --- a/addons/quickmount/functions/fnc_addFreeSeatsActions.sqf +++ b/addons/quickmount/functions/fnc_addFreeSeatsActions.sqf @@ -83,7 +83,7 @@ private _fnc_move = { {params ["_target", "_player", "_currentTurret"]; IS_MOVED_OUT}, { params ["", "_player", "", "_moveInCode", "_moveInParams", "_moveBackCode", "_moveBackParams"]; - LOG_2("moved out after %1 frames",diag_frameNo-GVAR(frame),call {GVAR(frame)=diag_frameNo; 0}); + LOG_2("moved out after %1 frames %2",diag_frameNo-GVAR(frame),call {GVAR(frame)=diag_frameNo; 0}); [_player, _moveInParams] call _moveInCode; WAIT_IN_OR_MOVE_BACK; }, diff --git a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf index 078af4d887b..cf4a8d5b227 100644 --- a/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf +++ b/addons/rearm/functions/fnc_getNeedRearmMagazines.sqf @@ -32,8 +32,6 @@ private _magazineInfo = []; // 1.70 pylons private _pylonConfigs = configProperties [configOf _vehicle >> "Components" >> "TransportPylonsComponent" >> "Pylons", "isClass _x"]; { - private _pylonConfig = _x; - // Strangely, a 1-based index. private _pylonIndex = _forEachIndex + 1; diff --git a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf index ace43baf8f9..a1aebc06331 100644 --- a/addons/rearm/functions/fnc_rearmSuccessLocal.sqf +++ b/addons/rearm/functions/fnc_rearmSuccessLocal.sqf @@ -49,7 +49,6 @@ if (_pylon > 0) exitWith { }; }; -private _currentRounds = 0; private _maxMagazines = [_vehicle, _turretPath, _magazineClass] call FUNC(getMaxMagazines); private _ammoCounts = [_vehicle, _turretPath, _magazineClass] call FUNC(getTurretMagazineAmmo); TRACE_3("start",_magazineClass,_maxMagazines,_ammoCounts); diff --git a/addons/switchunits/functions/fnc_markAiOnMap.sqf b/addons/switchunits/functions/fnc_markAiOnMap.sqf index 203ba426ffe..f2c02edbd28 100644 --- a/addons/switchunits/functions/fnc_markAiOnMap.sqf +++ b/addons/switchunits/functions/fnc_markAiOnMap.sqf @@ -40,7 +40,7 @@ GVAR(AllMarkerNames) = []; private _markerName = str _x; - private _marker = createMarkerLocal [_markerName, position _x]; + createMarkerLocal [_markerName, position _x]; _markerName setMarkerTypeLocal "mil_triangle"; _markerName setMarkerShapeLocal "ICON"; _markerName setMarkerSizeLocal [0.5, 0.7]; diff --git a/addons/tagging/functions/fnc_compileConfigTags.sqf b/addons/tagging/functions/fnc_compileConfigTags.sqf index d2f096d0678..a71d1992356 100644 --- a/addons/tagging/functions/fnc_compileConfigTags.sqf +++ b/addons/tagging/functions/fnc_compileConfigTags.sqf @@ -16,7 +16,6 @@ */ { - private _class = configName _x; private _result = [_x, false] call FUNC(parseConfigTag); if (_result isNotEqualTo []) then { @@ -28,7 +27,6 @@ } forEach ("true" configClasses (configFile >> "ACE_Tags")); { - private _class = configName _x; private _result = [_x, true] call FUNC(parseConfigTag); if (_result isNotEqualTo []) then { diff --git a/addons/trenches/functions/fnc_placeConfirm.sqf b/addons/trenches/functions/fnc_placeConfirm.sqf index 2cfdaf8891e..351c45c74dc 100644 --- a/addons/trenches/functions/fnc_placeConfirm.sqf +++ b/addons/trenches/functions/fnc_placeConfirm.sqf @@ -62,7 +62,7 @@ for [{private _ix = -_dx/2},{_ix <= _dx/2},{_ix = _ix + _dx/3}] do { _minzoffset = _minzoffset min ((getTerrainHeightASL _pos) - (_pos select 2)); #ifdef DEBUG_MODE_FULL _pos set [2, getTerrainHeightASL _pos]; - _pos2 = +_pos; + private _pos2 = +_pos; _pos2 set [2, getTerrainHeightASL _pos + 1]; drawLine3D [ASLToAGL _pos, ASLToAGL _pos2, [1,1,0,1]]; #endif diff --git a/addons/trenches/functions/fnc_placeTrench.sqf b/addons/trenches/functions/fnc_placeTrench.sqf index 285fe278e94..34ace22543c 100644 --- a/addons/trenches/functions/fnc_placeTrench.sqf +++ b/addons/trenches/functions/fnc_placeTrench.sqf @@ -75,7 +75,7 @@ GVAR(digPFH) = [{ _minzoffset = _minzoffset min ((getTerrainHeightASL _pos) - (_pos select 2)); #ifdef DEBUG_MODE_FULL _pos set [2, getTerrainHeightASL _pos]; - _pos2 = +_pos; + private _pos2 = +_pos; _pos2 set [2, getTerrainHeightASL _pos + 1]; drawLine3D [ASLToAGL _pos, ASLToAGL _pos2, [1,1,0,1]]; #endif diff --git a/addons/vehicle_damage/functions/fnc_addEventHandler.sqf b/addons/vehicle_damage/functions/fnc_addEventHandler.sqf index 3fdbf9ec20c..a0ac6053f74 100644 --- a/addons/vehicle_damage/functions/fnc_addEventHandler.sqf +++ b/addons/vehicle_damage/functions/fnc_addEventHandler.sqf @@ -102,7 +102,7 @@ private _fnc_iterateThroughConfig = { _hitPointHash set [_configName, ["slat", abs getNumber (_config >> "minimalHit")]]; }; - TRACE_6("found gun/turret/era/slat/misc",_isGun,_isTurret,_isEra,_isSlat,_isMisc,_hash); + TRACE_6("found gun/turret/era/slat/misc",_isGun,_isTurret,_isEra,_isSlat,_isMisc,_hitPointHash); } else { { _x call _fnc_iterateThroughConfig;