From 2b05f6f451cfa28bb23c4f408400cc6796a25a0c Mon Sep 17 00:00:00 2001 From: commy2 Date: Mon, 30 Nov 2015 17:22:16 +0100 Subject: [PATCH] fix isNil capitalization --- addons/cargo/functions/fnc_onMenuOpen.sqf | 2 +- addons/common/functions/fnc_blurScreen.sqf | 2 +- addons/common/functions/fnc_onAnswerRequest.sqf | 6 +++--- addons/medical/functions/fnc_addUnconsciousCondition.sqf | 2 +- addons/medical/functions/fnc_canTreat.sqf | 4 ++-- addons/medical/functions/fnc_createLitter.sqf | 2 +- addons/medical/functions/fnc_displayPatientInformation.sqf | 4 ++-- addons/medical/functions/fnc_displayTriageCard.sqf | 2 +- addons/medical/functions/fnc_dropDownTriageCard.sqf | 2 +- addons/medical/functions/fnc_getUnconsciousCondition.sqf | 2 +- addons/medical/functions/fnc_handleUnitVitals.sqf | 2 +- addons/medical/functions/fnc_hasItem.sqf | 2 +- addons/medical/functions/fnc_hasMedicalEnabled.sqf | 2 +- addons/medical/functions/fnc_treatment.sqf | 6 +++--- addons/medical/functions/fnc_useItem.sqf | 2 +- addons/modules/XEH_postInit.sqf | 2 +- addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf | 4 ++-- addons/repair/functions/fnc_canRepair.sqf | 4 ++-- addons/repair/functions/fnc_repair.sqf | 6 +++--- addons/zeus/functions/fnc_bi_moduleCurator.sqf | 2 +- addons/zeus/functions/fnc_bi_moduleProjectile.sqf | 4 ++-- 21 files changed, 32 insertions(+), 32 deletions(-) diff --git a/addons/cargo/functions/fnc_onMenuOpen.sqf b/addons/cargo/functions/fnc_onMenuOpen.sqf index 85557835bf..69c5db8e35 100644 --- a/addons/cargo/functions/fnc_onMenuOpen.sqf +++ b/addons/cargo/functions/fnc_onMenuOpen.sqf @@ -25,7 +25,7 @@ uiNamespace setVariable [QGVAR(menuDisplay), _display]; private ["_display","_loaded", "_ctrl", "_class", "_label"]; disableSerialization; _display = uiNamespace getVariable QGVAR(menuDisplay); - if (isnil "_display") exitWith { + if (isNil "_display") exitWith { [_this select 1] call CBA_fnc_removePerFrameHandler; }; diff --git a/addons/common/functions/fnc_blurScreen.sqf b/addons/common/functions/fnc_blurScreen.sqf index a3394a1fbf..005f422bc1 100644 --- a/addons/common/functions/fnc_blurScreen.sqf +++ b/addons/common/functions/fnc_blurScreen.sqf @@ -28,7 +28,7 @@ if (_show) then { GVAR(SHOW_BLUR_SCREEN_COLLECTION) pushBack _id; // show blur - if (isnil QGVAR(MENU_ppHandle_GUI_BLUR_SCREEN)) then { + if (isNil QGVAR(MENU_ppHandle_GUI_BLUR_SCREEN)) then { GVAR(MENU_ppHandle_GUI_BLUR_SCREEN) = ppEffectCreate ["DynamicBlur", 102]; GVAR(MENU_ppHandle_GUI_BLUR_SCREEN) ppEffectAdjust [0.9]; GVAR(MENU_ppHandle_GUI_BLUR_SCREEN) ppEffectEnable true; diff --git a/addons/common/functions/fnc_onAnswerRequest.sqf b/addons/common/functions/fnc_onAnswerRequest.sqf index b1639eb970..35b719bfda 100644 --- a/addons/common/functions/fnc_onAnswerRequest.sqf +++ b/addons/common/functions/fnc_onAnswerRequest.sqf @@ -18,7 +18,7 @@ private ["_requestID", "_info", "_callBack", "_caller", "_replyParams", "_reques _info = _unit getvariable _id; -if (!isnil "_info") then { +if (!isNil "_info") then { _caller = _info select 0; _target = _info select 1; _requestID = _info select 2; @@ -31,11 +31,11 @@ if (!isnil "_info") then { GVAR(RECIEVE_REQUEST_ID_KEY_BINDING) = nil; -if (!isnil QGVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT)) then { +if (!isNil QGVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT)) then { _unit removeAction GVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT); GVAR(RECIEVE_REQUEST_ADD_ACTION_ACCEPT) = nil; }; -if (!isnil QGVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE)) then { +if (!isNil QGVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE)) then { _unit removeAction GVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE); GVAR(RECIEVE_REQUEST_ADD_ACTION_DECLINE) = nil; }; diff --git a/addons/medical/functions/fnc_addUnconsciousCondition.sqf b/addons/medical/functions/fnc_addUnconsciousCondition.sqf index 4936abb5ef..3ded97f355 100644 --- a/addons/medical/functions/fnc_addUnconsciousCondition.sqf +++ b/addons/medical/functions/fnc_addUnconsciousCondition.sqf @@ -12,7 +12,7 @@ */ #include "script_component.hpp" -if (isnil QGVAR(unconsciousConditions)) then { +if (isNil QGVAR(unconsciousConditions)) then { GVAR(unconsciousConditions) = []; }; if (typeName _this == typeName []) then { diff --git a/addons/medical/functions/fnc_canTreat.sqf b/addons/medical/functions/fnc_canTreat.sqf index a23e012e5d..93a114599c 100644 --- a/addons/medical/functions/fnc_canTreat.sqf +++ b/addons/medical/functions/fnc_canTreat.sqf @@ -52,7 +52,7 @@ if !("All" in _allowedSelections || {(_selectionName in _allowedSelections)}) ex _return = true; if (getText (_config >> "condition") != "") then { _condition = getText (_config >> "condition"); - if (isnil _condition) then { + if (isNil _condition) then { _condition = compile _condition; } else { _condition = missionNamespace getvariable _condition; @@ -83,7 +83,7 @@ _medVeh = {([_caller] call FUNC(isInMedicalVehicle)) || ([_target] call FUNC(isI if (_x == "field") exitWith {_return = true;}; if (_x == "MedicalFacility" && _medFacility) exitWith {_return = true;}; if (_x == "MedicalVehicle" && _medVeh) exitWith {_return = true;}; - if !(isnil _x) exitWith { + if !(isNil _x) exitWith { private "_val"; _val = missionNamespace getvariable _x; if (typeName _val == "SCALAR") then { diff --git a/addons/medical/functions/fnc_createLitter.sqf b/addons/medical/functions/fnc_createLitter.sqf index 4341fdd704..4e68edd124 100644 --- a/addons/medical/functions/fnc_createLitter.sqf +++ b/addons/medical/functions/fnc_createLitter.sqf @@ -66,7 +66,7 @@ _createdLitter = []; if (toLower _selection in [toLower _selectionName, "all"]) then { // in is case sensitve. We can be forgiving here, so lets use toLower. - if (isnil _litterCondition) then { + if (isNil _litterCondition) then { _litterCondition = if (_litterCondition != "") then {compile _litterCondition} else {{true}}; } else { _litterCondition = missionNamespace getvariable _litterCondition; diff --git a/addons/medical/functions/fnc_displayPatientInformation.sqf b/addons/medical/functions/fnc_displayPatientInformation.sqf index 667b7a184b..77f5c690cb 100644 --- a/addons/medical/functions/fnc_displayPatientInformation.sqf +++ b/addons/medical/functions/fnc_displayPatientInformation.sqf @@ -47,7 +47,7 @@ if (_show) then { disableSerialization; _display = uiNamespace getvariable QGVAR(DisplayInformation); - if (isnil "_display") exitWith { + if (isNil "_display") exitWith { [_idPFH] call CBA_fnc_removePerFrameHandler; }; @@ -77,7 +77,7 @@ if (_show) then { { private "_value"; _value = _target getvariable _x; - if !(isnil "_value") then { + if !(isNil "_value") then { _totalIvVolume = _totalIvVolume + (_target getvariable [_x, 0]); }; } foreach GVAR(IVBags); diff --git a/addons/medical/functions/fnc_displayTriageCard.sqf b/addons/medical/functions/fnc_displayTriageCard.sqf index 1355c7d11a..b691b3db4b 100644 --- a/addons/medical/functions/fnc_displayTriageCard.sqf +++ b/addons/medical/functions/fnc_displayTriageCard.sqf @@ -33,7 +33,7 @@ if (_show) then { disableSerialization; _display = uiNamespace getvariable QGVAR(triageCard); - if (isnil "_display") exitWith { + if (isNil "_display") exitWith { [_idPFH] call CBA_fnc_removePerFrameHandler; }; diff --git a/addons/medical/functions/fnc_dropDownTriageCard.sqf b/addons/medical/functions/fnc_dropDownTriageCard.sqf index d44d1fed7c..b3cead3cba 100644 --- a/addons/medical/functions/fnc_dropDownTriageCard.sqf +++ b/addons/medical/functions/fnc_dropDownTriageCard.sqf @@ -18,7 +18,7 @@ params ["_show"]; disableSerialization; _display = uiNamespace getvariable QGVAR(triageCard); -if (isnil "_display") exitWith {}; +if (isNil "_display") exitWith {}; _pos = [0,0,0,0]; if (_show) then { diff --git a/addons/medical/functions/fnc_getUnconsciousCondition.sqf b/addons/medical/functions/fnc_getUnconsciousCondition.sqf index 70f820d6a0..19d1c85020 100644 --- a/addons/medical/functions/fnc_getUnconsciousCondition.sqf +++ b/addons/medical/functions/fnc_getUnconsciousCondition.sqf @@ -16,7 +16,7 @@ private ["_unit","_return"]; params ["_unit"]; -if (isnil QGVAR(unconsciousConditions)) then { +if (isNil QGVAR(unconsciousConditions)) then { GVAR(unconsciousConditions) = []; }; diff --git a/addons/medical/functions/fnc_handleUnitVitals.sqf b/addons/medical/functions/fnc_handleUnitVitals.sqf index 0fa3607b52..8d52355b7c 100644 --- a/addons/medical/functions/fnc_handleUnitVitals.sqf +++ b/addons/medical/functions/fnc_handleUnitVitals.sqf @@ -184,7 +184,7 @@ if (GVAR(level) >= 2) then { { private "_value"; _value = _unit getvariable _x; - if !(isnil "_value") then { + if !(isNil "_value") then { _unit setvariable [_x,(_unit getvariable [_x, 0]), true]; }; } foreach GVAR(IVBags); diff --git a/addons/medical/functions/fnc_hasItem.sqf b/addons/medical/functions/fnc_hasItem.sqf index e70144f617..bc154fa792 100644 --- a/addons/medical/functions/fnc_hasItem.sqf +++ b/addons/medical/functions/fnc_hasItem.sqf @@ -18,7 +18,7 @@ private ["_medic", "_patient", "_item", "_return", "_crew"]; params ["_medic", "_patient", "_item"]; -if (isnil QGVAR(setting_allowSharedEquipment)) then { +if (isNil QGVAR(setting_allowSharedEquipment)) then { GVAR(setting_allowSharedEquipment) = true; }; if (GVAR(setting_allowSharedEquipment) && {[_patient, _item] call EFUNC(common,hasItem)}) exitWith { diff --git a/addons/medical/functions/fnc_hasMedicalEnabled.sqf b/addons/medical/functions/fnc_hasMedicalEnabled.sqf index 44f653286a..88dc084924 100644 --- a/addons/medical/functions/fnc_hasMedicalEnabled.sqf +++ b/addons/medical/functions/fnc_hasMedicalEnabled.sqf @@ -20,7 +20,7 @@ private "_medicalEnabled"; params ["_unit"]; _medicalEnabled = _unit getvariable QGVAR(enableMedical); -if (isnil "_medicalEnabled") exitWith { +if (isNil "_medicalEnabled") exitWith { (((GVAR(enableFor) == 0 && (isPlayer _unit || (_unit getvariable [QEGVAR(common,isDeadPlayer), false])))) || (GVAR(enableFor) == 1) || GVAR(level) == 1) }; diff --git a/addons/medical/functions/fnc_treatment.sqf b/addons/medical/functions/fnc_treatment.sqf index 9b373df77e..50f34f765a 100644 --- a/addons/medical/functions/fnc_treatment.sqf +++ b/addons/medical/functions/fnc_treatment.sqf @@ -60,7 +60,7 @@ _return = true; if (isText (_config >> "Condition")) then { _condition = getText(_config >> "condition"); if (_condition != "") then { - if (isnil _condition) then { + if (isNil _condition) then { _condition = compile _condition; } else { _condition = missionNamespace getvariable _condition; @@ -95,7 +95,7 @@ if ("All" in _locations) then { if (_x == "field") exitWith {_return = true;}; if (_x == "MedicalFacility" && _medFacility) exitWith {_return = true;}; if (_x == "MedicalVehicle" && _medVeh) exitWith {_return = true;}; - if !(isnil _x) exitWith { + if !(isNil _x) exitWith { private "_val"; _val = missionNamespace getvariable _x; if (typeName _val == "SCALAR") then { @@ -200,7 +200,7 @@ _treatmentTime = if (isNumber (_config >> "treatmentTime")) then { } else { if (isText (_config >> "treatmentTime")) exitWith { _treatmentTimeConfig = getText(_config >> "treatmentTime"); - if (isnil _treatmentTimeConfig) then { + if (isNil _treatmentTimeConfig) then { _treatmentTimeConfig = compile _treatmentTimeConfig; } else { _treatmentTimeConfig = missionNamespace getvariable _treatmentTimeConfig; diff --git a/addons/medical/functions/fnc_useItem.sqf b/addons/medical/functions/fnc_useItem.sqf index ed2d402bc6..e9be5cf359 100644 --- a/addons/medical/functions/fnc_useItem.sqf +++ b/addons/medical/functions/fnc_useItem.sqf @@ -19,7 +19,7 @@ private ["_return","_crew"]; params ["_medic", "_patient", "_item"]; -if (isnil QGVAR(setting_allowSharedEquipment)) then { +if (isNil QGVAR(setting_allowSharedEquipment)) then { GVAR(setting_allowSharedEquipment) = true; }; diff --git a/addons/modules/XEH_postInit.sqf b/addons/modules/XEH_postInit.sqf index 56b7cce091..bbc27b7eef 100644 --- a/addons/modules/XEH_postInit.sqf +++ b/addons/modules/XEH_postInit.sqf @@ -21,7 +21,7 @@ private _isPersistent = getNumber (_config >> "isPersistent") > 0 || getnumber (_config >> "isGlobal") > 1; private _isSingular = getNumber (_config >> "isSingular") > 0; private _function = getText (_config >> "function"); - if (isnil _function) then { + if (isNil _function) then { _function = compile _function; } else { _function = missionNamespace getvariable _function; diff --git a/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf b/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf index 755982e569..1f09ff271c 100644 --- a/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf +++ b/addons/optionsmenu/functions/fnc_debugDumpToClipboard.sqf @@ -67,7 +67,7 @@ _text = format [" { _var = missionNamespace getVariable [_x, nil]; - if(!isnil "_var" && {(typeName _var) == "ARRAY"} && {(count _var) > MIN_ARRAY_SIZE}) then { + if(!isNil "_var" && {(typeName _var) == "ARRAY"} && {(count _var) > MIN_ARRAY_SIZE}) then { _text = format ["%1 - ARRAY SIZE: %2", _x, (count _var)]; [_text] call _outputText; }; @@ -77,7 +77,7 @@ _text = format [" _unit = _x; { _var = _unit getVariable [_x, nil]; - if(!isnil "_var" && {(typeName _var) == "ARRAY"} && {(count _var) > MIN_ARRAY_SIZE}) then { + if(!isNil "_var" && {(typeName _var) == "ARRAY"} && {(count _var) > MIN_ARRAY_SIZE}) then { _text = format ["%1 on [%2] - ARRAY SIZE: %3", _x, _unit, (count _var)]; [_text] call _outputText; }; diff --git a/addons/repair/functions/fnc_canRepair.sqf b/addons/repair/functions/fnc_canRepair.sqf index a12a61104f..d4ffb23886 100644 --- a/addons/repair/functions/fnc_canRepair.sqf +++ b/addons/repair/functions/fnc_canRepair.sqf @@ -54,7 +54,7 @@ if (count _items > 0 && {!([_caller, _items] call FUNC(hasItems))}) exitWith {fa _return = true; if (getText (_config >> "condition") != "") then { _condition = getText (_config >> "condition"); - if (isnil _condition) then { + if (isNil _condition) then { _condition = compile _condition; } else { _condition = missionNamespace getVariable _condition; @@ -86,7 +86,7 @@ _repairVeh = {([_caller] call FUNC(isNearRepairVehicle)) || ([_target] call FUNC if (_x == "field") exitWith {_return = true;}; if (_x == "RepairFacility" && _repairFacility) exitWith {_return = true;}; if (_x == "RepairVehicle" && _repairVeh) exitWith {_return = true;}; - if !(isnil _x) exitWith { + if !(isNil _x) exitWith { private "_val"; _val = missionNamespace getVariable _x; if (typeName _val == "SCALAR") then { diff --git a/addons/repair/functions/fnc_repair.sqf b/addons/repair/functions/fnc_repair.sqf index 841ede0ea0..cf2d4276cf 100644 --- a/addons/repair/functions/fnc_repair.sqf +++ b/addons/repair/functions/fnc_repair.sqf @@ -54,7 +54,7 @@ if (count _items > 0 && {!([_caller, _items] call FUNC(hasItems))}) exitWith {fa _return = true; if (getText (_config >> "condition") != "") then { _condition = getText (_config >> "condition"); - if (isnil _condition) then { + if (isNil _condition) then { _condition = compile _condition; } else { _condition = missionNamespace getVariable _condition; @@ -85,7 +85,7 @@ _repairVeh = {([_caller] call FUNC(isNearRepairVehicle)) || ([_target] call FUNC if (_x == "field") exitWith {_return = true;}; if (_x == "RepairFacility" && _repairFacility) exitWith {_return = true;}; if (_x == "RepairVehicle" && _repairVeh) exitWith {_return = true;}; - if !(isnil _x) exitWith { + if !(isNil _x) exitWith { private "_val"; _val = missionNamespace getVariable _x; if (typeName _val == "SCALAR") then { @@ -162,7 +162,7 @@ _repairTime = if (isNumber (_config >> "repairingTime")) then { } else { if (isText (_config >> "repairingTime")) exitWith { _repairTimeConfig = getText(_config >> "repairingTime"); - if (isnil _repairTimeConfig) then { + if (isNil _repairTimeConfig) then { _repairTimeConfig = compile _repairTimeConfig; } else { _repairTimeConfig = missionNamespace getVariable _repairTimeConfig; diff --git a/addons/zeus/functions/fnc_bi_moduleCurator.sqf b/addons/zeus/functions/fnc_bi_moduleCurator.sqf index 109a4c502a..88f85557a7 100644 --- a/addons/zeus/functions/fnc_bi_moduleCurator.sqf +++ b/addons/zeus/functions/fnc_bi_moduleCurator.sqf @@ -319,7 +319,7 @@ if (_activated) then { //--- Show hint about pinging for players if ( - isnil {profilenamespace getvariable "bis_fnc_curatorPinged_done"} + isNil {profilenamespace getvariable "bis_fnc_curatorPinged_done"} && {isTutHintsEnabled} && diff --git a/addons/zeus/functions/fnc_bi_moduleProjectile.sqf b/addons/zeus/functions/fnc_bi_moduleProjectile.sqf index f88ea5d391..534b4fce10 100644 --- a/addons/zeus/functions/fnc_bi_moduleProjectile.sqf +++ b/addons/zeus/functions/fnc_bi_moduleProjectile.sqf @@ -17,7 +17,7 @@ #include "script_component.hpp" -_fnc_scriptNameParentTemp = if !(isnil '_fnc_scriptName') then {_fnc_scriptName} else {'BIS_fnc_moduleProjectile'}; +_fnc_scriptNameParentTemp = if !(isNil '_fnc_scriptName') then {_fnc_scriptName} else {'BIS_fnc_moduleProjectile'}; private ['_fnc_scriptNameParent']; _fnc_scriptNameParent = _fnc_scriptNameParentTemp; _fnc_scriptNameParentTemp = nil; @@ -128,7 +128,7 @@ if (_activated) then { if (_attach) then {_projectile attachto [_logic,[0,0,_altitude]];}; // Added by ace_zeus for ace_frag compatibility - if (!isnil QEFUNC(frag,addPfhRound)) then { + if (!isNil QEFUNC(frag,addPfhRound)) then { [objNull, _ammo, _projectile, true] call EFUNC(frag,addPfhRound); };