MisterHLunaticwraith / MRHMilsimTools

Files for the mod mrh milsim tools
Other
10 stars 10 forks source link

Biometrics returning False; door still opening. #30

Closed trapw0w closed 5 years ago

trapw0w commented 5 years ago

Arma 3 Version: 1.94 (stable / rc / dev) CBA Version: 3.12.2 (stable / dev + commit hash) ACE3 Version: 3.12.6 (stable / rc / dev) Milsim Tools Version: 1.17.5 (stable / rc / dev)

Mods:

- CBA_A3
- ACE3
- MRH Milsim Tools

Description:

Steps to reproduce:

Where did the issue occur?

RPT log file:

18:27:54 [CBA] (events) WARNING: Usage of deprecated CBA_fnc_addLocalEventHandler backwards_comp.sqf:76
18:28:10 OPC DATA [2,"76561198079109911","Trap",false,2]
18:28:10 "1"
18:28:10 "MRHMilsimTools Init Player Variables- no role defined for unit: test2 "
18:28:10 "MRH_MilsimToolsCore Player Connected EH Fired"
18:28:10  Mission id: 96c3b051a63c5b0fd37b12e26ca3f39a297bdb15
18:28:10 "MRH_fnc_MilsimTools_Core_InitPlayerLocal: 23/9/2019 at 00:13:50:58 - Player initialized InitPlayerLocal starting -Locality: Hosted by: Trap ID:2"
18:28:10 "MRH_fnc_MilsimTools_Core_InitPlayerLocal: 23/9/2019 at 00:13:50:58 - Player initialized InitPlayerLocal Done -Locality: Hosted by: Trap ID:2"
18:28:10 "MRH_fnc_MilsimTools_Core_cbaEventHandlersPlayer: 23/9/2019 at 00:13:50:58 - Player CBA Even tHandlers Added -Locality: Hosted by: Trap ID:2"
18:28:10 "MRH_MilsimTools_UnknownFunction :23/9/2019 at 00:13:50:58 - EnhancedMap Xeh: Handlers added  -Locality: Hosted by: Trap ID:2"
18:28:11 "MRH_MilsimTools_Core Func GenAliveAndDead Called"
18:28:11 "MRH_fnc_MilsimTools_MiscItems_bioScannerInit: 23/9/2019 at 00:13:51:52 - Bioscanner 170f9ef3580# 7: mrh_bioscanner.p3d lock  engaged for building prae door 1 -Locality: Hosted by: Trap ID:2"
18:28:11 "MRH_MilsimTools_UnknownFunction :23/9/2019 at 00:13:51:54 - MRH BioScanner ace action added to 170f9ef3580# 7: mrh_bioscanner.p3d, action name MRH_Scanner_handScan, action [""MRH_Scanner_handScan"",""Scan hand"","""",{
_this spawn {

(_this select 2) params [""_scanner"",""_code"",""_part""]; 
_code = ""params ['_scanner','_player'];"" + _code;
if (_part == ""hand"") then 
{
playSound3D [""MRHMiscItems\Sounds\scanSound.ogg"", _scanner];
_videohand = [_scanner,""\MRHMiscItems\Videos\handScanHandScreen.ogv"",1] spawn MRH_fnc_MilsimTools_Core_playVideoOnObject;
waitUntil {scriptDone _videohand};
playSound3D [""MRHMiscItems\Sounds\computerInterface.ogg"", _scanner];
_videoMain = [_scanner,""\MRHMiscItems\Videos\handScanMainScreen.ogv"",0] spawn MRH_fnc_MilsimTools_Core_playVideoOnObject;
waitUntil {scriptDone _videoMain};
[_scanner,player,_code,_part] call MRH_fnc_MilsimTools_MiscItems_processCode;
_scanner setVariable [""MRH_playerHasScannedHand"",true];
};
if (_part == ""main"") then 
{
playSound3D [""MRHMisc
18:28:11 "MRH_MilsimTools_UnknownFunction :23/9/2019 at 00:13:51:54 - MRH BioScanner ace action added to 170f9ef3580# 7: mrh_bioscanner.p3d, action name MRH_Scanner_EyeScanner, action [""MRH_Scanner_EyeScanner"",""Scan eyes"","""",{
_this spawn {

(_this select 2) params [""_scanner"",""_code"",""_part""]; 
_code = ""params ['_scanner','_player'];"" + _code;
if (_part == ""hand"") then 
{
playSound3D [""MRHMiscItems\Sounds\scanSound.ogg"", _scanner];
_videohand = [_scanner,""\MRHMiscItems\Videos\handScanHandScreen.ogv"",1] spawn MRH_fnc_MilsimTools_Core_playVideoOnObject;
waitUntil {scriptDone _videohand};
playSound3D [""MRHMiscItems\Sounds\computerInterface.ogg"", _scanner];
_videoMain = [_scanner,""\MRHMiscItems\Videos\handScanMainScreen.ogv"",0] spawn MRH_fnc_MilsimTools_Core_playVideoOnObject;
waitUntil {scriptDone _videoMain};
[_scanner,player,_code,_part] call MRH_fnc_MilsimTools_MiscItems_processCode;
_scanner setVariable [""MRH_playerHasScannedHand"",true];
};
if (_part == ""main"") then 
{
playSound3D [""MRH
18:28:11 "MRH_MilsimTools_UnknownFunction :23/9/2019 at 00:13:51:54 - MRH BioScanner ace action added to 170f9ef3580# 7: mrh_bioscanner.p3d, action name MRH_Scanner_MainScreenAction, action [""MRH_Scanner_MainScreenAction"",""Touch screen"","""",{
_this spawn {

(_this select 2) params [""_scanner"",""_code"",""_part""]; 
_code = ""params ['_scanner','_player'];"" + _code;
if (_part == ""hand"") then 
{
playSound3D [""MRHMiscItems\Sounds\scanSound.ogg"", _scanner];
_videohand = [_scanner,""\MRHMiscItems\Videos\handScanHandScreen.ogv"",1] spawn MRH_fnc_MilsimTools_Core_playVideoOnObject;
waitUntil {scriptDone _videohand};
playSound3D [""MRHMiscItems\Sounds\computerInterface.ogg"", _scanner];
_videoMain = [_scanner,""\MRHMiscItems\Videos\handScanMainScreen.ogv"",0] spawn MRH_fnc_MilsimTools_Core_playVideoOnObject;
waitUntil {scriptDone _videoMain};
[_scanner,player,_code,_part] call MRH_fnc_MilsimTools_MiscItems_processCode;
_scanner setVariable [""MRH_playerHasScannedHand"",true];
};
if (_part == ""main"") then 
{
pla
18:28:15 ["TFAR_SendRadioRequest",["ItemRadio"],0.017,5.03]
18:28:15 "TFAR_RadioRequestEvent [[""ItemRadio""],test2] 1639.3"
18:28:15 "Send TFAR_RadioRequestResponseEvent [1] 1639.3"
18:28:15 ["TFAR_ReceiveRadioRequestResponse",[1]]
18:28:25 "FALSE!!!!!!!"
18:28:26 "FALSE!!!!!!!"
18:28:37 "FALSE!!!!!!!"
18:28:52 "FALSE!!!!!!!"
18:28:57 "FALSE!!!!!!!"

These lines are as a result of an IF statement in the init of the biometric scanner to detect if the unit has the trait:

18:28:25 "FALSE!!!!!!!"
18:28:26 "FALSE!!!!!!!"
18:28:37 "FALSE!!!!!!!"
18:28:52 "FALSE!!!!!!!"
18:28:57 "FALSE!!!!!!!"
MisterHLunaticwraith commented 5 years ago

_player like this is a private variable, it can't work unless you define it. Now the script passes _scanner and _player as parameters to the condition but you have to "catch" them in you script, so that would be either:

params ["_scanner,"_player"]; _player getUnitTrait "testunit"

or (_this select 1) getUnitTrait "testunit"

(verified and tested, works as intended) Close ?