enderalse/source/scripts/_00e_nq09_tombriddleactivatorscript.psc

165 lines
5.5 KiB
Plaintext
Raw Normal View History

Scriptname _00E_NQ09_TombRiddleActivatorScript extends ObjectReference
bool bBlockTranslation = false
int iCorrectValue = 0
bool bUpDown = true
Event onActivate(objectReference actronaut)
if ( bBlockTranslation == false)
if ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_01 )
MoveObject(_00E_NQ09_TombRiddleActivator_01ref, _00E_NQ09_TombRiddleActivator_01_MUPref, _00E_NQ09_TombRiddleActivator_01_MDOWNref, 1)
elseif ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_02 )
MoveObject(_00E_NQ09_TombRiddleActivator_02ref, _00E_NQ09_TombRiddleActivator_02_MUPref, _00E_NQ09_TombRiddleActivator_02_MDOWNref, 2)
elseif ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_03 )
MoveObject(_00E_NQ09_TombRiddleActivator_03ref, _00E_NQ09_TombRiddleActivator_03_MUPref, _00E_NQ09_TombRiddleActivator_03_MDOWNref, 3)
elseif ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_04 )
MoveObject(_00E_NQ09_TombRiddleActivator_04ref, _00E_NQ09_TombRiddleActivator_04_MUPref, _00E_NQ09_TombRiddleActivator_04_MDOWNref, 4)
elseif ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_05 )
MoveObject(_00E_NQ09_TombRiddleActivator_05ref, _00E_NQ09_TombRiddleActivator_05_MUPref, _00E_NQ09_TombRiddleActivator_05_MDOWNref, 5)
elseif ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_06 )
MoveObject(_00E_NQ09_TombRiddleActivator_06ref, _00E_NQ09_TombRiddleActivator_06_MUPref, _00E_NQ09_TombRiddleActivator_06_MDOWNref, 6)
elseif ( Self.GetBaseObject() == _00E_NQ09_TombRiddleActivator_07 )
MoveObject(_00E_NQ09_TombRiddleActivator_07ref, _00E_NQ09_TombRiddleActivator_07_MUPref, _00E_NQ09_TombRiddleActivator_07_MDOWNref, 7)
endif
endif
EndEvent
Event OnTranslationComplete()
bBlockTranslation = false;
int soundcont_MoveEnd = _00E_OBJDwemerGearsStuck.Play(Self)
CheckRiddle()
EndEvent
Function CheckRiddle()
;Solution
if ( NQ09Script.bCorrect == false )
if ( NQ09Script.iRight1 == 1 )
if ( NQ09Script.iRight2 == 0 )
if ( NQ09Script.iRight3 == 1 )
if ( NQ09Script.iRight4 == 1 )
if ( NQ09Script.iRight5 == 1 )
if ( NQ09Script.iRight6 == 0 )
if ( NQ09Script.iRight7 == 1 )
NQ09.SetStage(50)
NQ09Script.bCorrect = true
NQ09Script.OpenSecretPassage()
EndIf
EndIf
EndIf
EndIf
EndIf
EndIf
EndIf
Endif
Endfunction
Function MoveObject(ObjectReference Object, objectReference MarkerUP, objectReference MarkerDOWN, int Type)
; MOVE
if (bUpDown == true)
bUpDown = false
Object.TranslateToRef( MarkerUP, 0.05 )
else
bUpDown = true
Object.TranslateToRef( MarkerDOWN, 0.05 )
endif
if (bUpDown == false)
if ( Type == 1 )
;Debug.MessageBox("1")
NQ09Script.iRight1 = 1
elseif ( Type == 2 )
;Debug.MessageBox("2")
NQ09Script.iRight2 = 1
elseif( Type == 3 )
;Debug.MessageBox("3")
NQ09Script.iRight3 = 1
elseif ( Type == 4 )
;Debug.MessageBox("4")
NQ09Script.iRight4 = 1
elseif ( Type == 5 )
;Debug.MessageBox("5")
NQ09Script.iRight5 = 1
elseif( Type == 6 )
;Debug.MessageBox("6")
NQ09Script.iRight6 = 1
elseif( Type == 7 )
;Debug.MessageBox("7")
NQ09Script.iRight7 = 1
endif
elseif(bUpDown == true)
if ( Type == 1 )
NQ09Script.iRight1 = 0
elseif( Type == 2 )
NQ09Script.iRight2 = 0
elseif( Type == 3 )
NQ09Script.iRight3 = 0
elseif ( Type == 4 )
NQ09Script.iRight4 = 0
elseif( Type == 5 )
NQ09Script.iRight5 = 0
elseif( Type == 6 )
NQ09Script.iRight6 = 0
elseif( Type == 7 )
NQ09Script.iRight7 = 0
endif
endif
EndFunction
_00E_NQ09_Functions Property NQ09Script Auto ;ACCESS TO QUEST SCRIPT
Quest Property NQ09 auto
Sound Property _00E_OBJDwemerGearsStuck Auto
Activator Property _00E_NQ09_TombRiddleActivator_01 Auto
Activator Property _00E_NQ09_TombRiddleActivator_02 Auto
Activator Property _00E_NQ09_TombRiddleActivator_03 Auto
Activator Property _00E_NQ09_TombRiddleActivator_04 Auto
Activator Property _00E_NQ09_TombRiddleActivator_05 Auto
Activator Property _00E_NQ09_TombRiddleActivator_06 Auto
Activator Property _00E_NQ09_TombRiddleActivator_07 Auto
objectReference property _00E_NQ09_TombRiddleActivator_01ref auto
objectReference property _00E_NQ09_TombRiddleActivator_02ref auto
objectReference property _00E_NQ09_TombRiddleActivator_03ref auto
objectReference property _00E_NQ09_TombRiddleActivator_04ref auto
objectReference property _00E_NQ09_TombRiddleActivator_05ref auto
objectReference property _00E_NQ09_TombRiddleActivator_06ref auto
objectReference property _00E_NQ09_TombRiddleActivator_07ref auto
objectReference property _00E_NQ09_TombRiddleActivator_01_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_02_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_03_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_04_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_05_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_06_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_07_MUPref auto
objectReference property _00E_NQ09_TombRiddleActivator_01_MDOWNref auto
objectReference property _00E_NQ09_TombRiddleActivator_02_MDOWNref auto
objectReference property _00E_NQ09_TombRiddleActivator_03_MDOWNref auto
objectReference property _00E_NQ09_TombRiddleActivator_04_MDOWNref auto
objectReference property _00E_NQ09_TombRiddleActivator_05_MDOWNref auto
objectReference property _00E_NQ09_TombRiddleActivator_06_MDOWNref auto
objectReference property _00E_NQ09_TombRiddleActivator_07_MDOWNref auto