4
Fork 0
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

49 lines
1.4 KiB

Scriptname _00E_Game_SkillMenuLeaveSC extends ObjectReference
;=====================================================================================
; EVENTS
;=====================================================================================
Event OnKeyDown(Int KeyCode)
If KeyCode == (iMappedKeyCode) && Utility.IsInMenuMode() == False && UI.IsTextInputEnabled() == False
_00E_Class_OpenClassMenuSpell.Cast(PlayerREF, PlayerREF)
UnregisterForKey(Input.GetMappedKey("Shout"))
EndIf
EndEvent
Event OnTriggerLeave(ObjectReference akActionRef)
If akActionRef == PlayerREF
UnregisterForKey(Input.GetMappedKey("Shout"))
_00E_A2_GhostwalkSneakFailsave.SetValue(PlayerREF.GetActorValue("Sneak"))
EndIf
EndEvent
Event OnTriggerEnter(ObjectReference akActionRef)
If akActionRef == PlayerREF && MQP03.GetStage() >= 15
iMappedKeyCode = Input.GetMappedKey("Shout")
RegisterForKey(iMappedKeyCode)
Game.RequestAutoSave()
EndIf
EndEvent
;=====================================================================================
; PROPERTIES
;=====================================================================================
int iMappedKeyCode
Actor Property PlayerREF Auto
Quest Property MQP03 Auto
Spell Property _00E_Class_OpenClassMenuSpell Auto
GlobalVariable Property _00E_A2_GhostwalkSneakFailsave Auto