Refresh heat vision on item equip

This commit is contained in:
Eddoursul 2024-04-28 14:33:14 +02:00
parent 68c6a351de
commit 69da4522a9
3 changed files with 10 additions and 0 deletions

Binary file not shown.

View File

@ -0,0 +1,8 @@
scn CWxBionicEyesOnEquip
begin function { ref rEquipper, ref rEquipped }
let CWxBionicEyesQuest.heatShader1stPersonActive := 0
let CWxBionicEyesQuest.heatShader3rdPersonActive := 0
end

View File

@ -8,6 +8,7 @@ begin function { iMode }
SetOnKeyUpEventHandler CWxBionicEyesOnHotkey 1 CWxVisionModeHotkey
SetOnControlDownEventHandler CWxBionicEyesOnHotkey 1 27 ; Grab
SetEventHandler "OnActorEquip" CWxBionicEyesOnEquip
; Clear list of processed actors to reapply shaders
if CWxVisionModeLevel > 0
@ -18,6 +19,7 @@ begin function { iMode }
else
SetOnKeyUpEventHandler CWxBionicEyesOnHotkey 0 CWxVisionModeHotkey
SetOnControlDownEventHandler CWxBionicEyesOnHotkey 0 27 ; Grab
RemoveEventHandler "OnActorEquip" CWxBionicEyesOnEquip
endif
end