home *** CD-ROM | disk | FTP | other *** search
/ CyberMycha 2006 April / SGP.iso / dema / Keepsake-Demo-en-li-v1.0.exe / res / scripts / enchantedHallway.tcl < prev    next >
Text File  |  2005-12-06  |  25KB  |  805 lines

  1. ################################################################################
  2. #                                                                             ##
  3. #    file   enchantedHallway.tcl                                              ##
  4. #    brief  Events for the Enchanted Hallway.                                 ##
  5. #                                                                             ##
  6. ################################################################################
  7.  
  8.  
  9. ## ===================================================== ##
  10. ##   Loading script from source                          ##
  11. ## ===================================================== ##
  12.  
  13. source "[AUTO]/enchantedHallway.mvwrap.tcl"
  14. source "[PUZZLES]/enchantedHallway.camera.tcl"
  15.  
  16.  
  17. ## ===================================================== ##
  18. ##   Initialization                                      ##
  19. ## ===================================================== ##
  20.  
  21. event "init" {
  22.   setAudioEnv "room"
  23.   if { [getVar "itemNoteBook"] == "pickedUp" && [getVar "bookCornerBehavior"] == "" && [getVar "puzzleZak"] == "complete" && [getVar "myasBook"] == "" } {
  24.     oz'track::stop $::music_track
  25.   } else {
  26.     oz'track::play $::music_track "sound/music/academy.ogg"
  27.   }
  28.   SetAmbient 2d ambiance/forest "0 0 0" 0 0
  29.   ozSet "enchantedHallwayRoom" "visited"
  30.   
  31.   ozSet "enchantedHallway.toEnchantedCrosswayClick" "false"
  32.   ozSet "enchantedHallway.toEnchantedCrossway" "false"
  33. }
  34.  
  35.  
  36. event "toEnchantedCrossway" {
  37.  
  38. }
  39.  
  40.  
  41. ################################################################################
  42. ## ========================================================================== ##
  43. ##   DOOR BLOCKING & PUZZLE SECTION                                           ##
  44. ## ========================================================================== ##
  45. ################################################################################
  46.  
  47.  
  48. ## ===================================================== ##
  49. ##   Notebook Behavior                                   ##
  50. ## ===================================================== ##
  51. ## Trigger is when the player take the Notebook
  52.  
  53. event "useNoteBook" {
  54.   eventState [wizEventStart "useNoteBook"]
  55.  
  56.   if { [getVar "puzzleZak"] == "" && [getVar "lostBook"] == "" } {
  57.     callEvent "lostBook"
  58.  
  59.   } elseif { [getVar "puzzleZak"] == "complete" && [getVar "myasBook"] == "" } {
  60.     callEvent "myasBook"
  61.   }
  62.   wizqEventEnd "useNoteBook"
  63. }
  64.  
  65.  
  66. ################################################################################
  67. ## ========================================================================== ##
  68. ##   MOVEMENT                                                                 ##
  69. ## ========================================================================== ##
  70. ################################################################################
  71.  
  72.  
  73. ## ===================================================== ##
  74. ##  transCorridor                                        ##
  75. ## ===================================================== ##
  76.  
  77. event "transCorridor" {
  78.   wizEntityMoveXRelative Lydia 0.47 0.89 "453 84.3 303.6" "453.5 84.3 277.6"
  79. }
  80.  
  81.  
  82. ## ===================================================== ##
  83. ##  transBookCorner                                      ##
  84. ## ===================================================== ##
  85.  
  86. event "transBookCorner" {
  87.   wizEntityMoveXRelative Lydia 0.15 0.56 "386.2 86.4 263" "386.2 86.4 277"
  88. }
  89.  
  90.  
  91. ## ===================================================== ##
  92. ##   Notebook                                            ##
  93. ## ===================================================== ##
  94.  
  95. event "useNotebook" {
  96.   eventState [wizEventStart "useNotebook"]
  97.  
  98.   if { [ozGet "puzzleZak"] == "complete" } {
  99.     # Block 1
  100.     wizqQueue 2 {
  101.       oz'event {wizEntityStopFollow Zak}
  102.       wizqEntityMove Zak "414.2 84.3 273" "wait"
  103.       wizqEntityOrientation Zak 220
  104.       oz'event {wizEntityResumeFollow Zak}
  105.     }
  106.   }
  107.  
  108.   wizqEntityMove Lydia [wizMinPosition "406 84.3 283" 2] "enchantedHallway.noteBookBehavior" 2
  109.  
  110.   wizqEventEnd "useNotebook"
  111. }
  112.  
  113.  
  114. ################################################################################
  115. ## ========================================================================== ##
  116. ## ANIMATION & SPECIAL CAMERA SECTION                                         ##
  117. ## ========================================================================== ##
  118. ################################################################################
  119.  
  120.  
  121. ## ===================================================== ##
  122. ##   Notebook                                            ##
  123. ## ===================================================== ##
  124. ## Trigger is when the player click on the Notebook
  125.  
  126. event "noteBookBehavior" {
  127.   if { [ozGet "puzzleZak"] == "complete" } {
  128.     # Block 1
  129.     wizqQueue 2 {
  130.       wizqEntityMove Zak "414.2 84.3 273" "wait"
  131.       wizqEntityOrientation Zak 220
  132.     }
  133.  
  134.     oz'event {wizEntityStopFollow Zak}
  135.   }
  136.  
  137.   oz'event {wizDisableMouse}
  138.   wizqEntityOrientation Lydia 180 "wait"
  139.   wizqEntitySetCycle Lydia standCycleNormal
  140.  
  141.   # Wait for Block 1
  142.   wizqWaitQueue 2
  143.  
  144.   oz'track::stop $::music_track
  145.  
  146.   chainEvent { wizEntityLookAt Zak [wizEntityGetPosition Lydia] }
  147.  
  148.   wizqEntityChangeCycle Lydia crouchCycleNormal standToCrouch "wait"
  149.   wizqZoomIn "notebookCloseUp" "enchantedHallway.notebookZoomOut"
  150.  
  151.   oz'event {wizEnableMouse}
  152.   oz'event {wizEntityResumeFollow Zak}
  153. }
  154.  
  155.  
  156. ## ===================================================== ##
  157. ##   Notebook Zoom Out                                   ##
  158. ## ===================================================== ##
  159.  
  160. event "notebookZoomOut" {
  161.   chainEvent {
  162.     freezePlayer
  163.     wizDisableMouse
  164.   }
  165.   
  166.   wizqEntitySetCycle Lydia crouchCycleNormal
  167.  
  168.   if { [getVar "itemNoteBook"] == "pickedUp" } {
  169.     wizqZoomOut "bookCornerNotesTaken"
  170.     chainEvent { hRemoveBack }
  171.     wizqDisableMouse
  172.  
  173.     chainEvent { delay 100 }
  174.     wizqEntityChangeCycle Lydia standCycleNormal crouchToStand "wait"
  175.  
  176.     chainEvent {
  177.       unfreezePlayer
  178.       wizEnableMouse
  179.     }
  180.   
  181.   } else {
  182.     wizqZoomOut "bookCorner"
  183.     chainEvent { hRemoveBack }
  184.     wizqDisableMouse
  185.  
  186.     chainEvent { delay 100 }
  187.     wizqEntityChangeCycle Lydia standCycleNormal crouchToStand "wait"
  188.  
  189.     chainEvent {
  190.       unfreezePlayer
  191.       wizEnableMouse
  192.     }
  193.   }
  194. }
  195.  
  196.  
  197. ## ===================================================== ##
  198. ##   Camera pickedUp                                     ##
  199. ## ===================================================== ##
  200. ## trigger is when the player is near the NoteBook
  201.  
  202. event "bookCorner" {
  203.   if { [getVar "itemNoteBook"] == "" } {
  204.     setCamera "bookCorner"
  205.     wizhCameraChange
  206.   }
  207.  
  208.   if { [getVar "itemNoteBook"] == "pickedUp" } {
  209.     if { [getVar "itemNoteBook"] == "pickedUp" && [getVar "bookCornerBehavior"] == "" && [getVar "puzzleZak"] == "complete" && [getVar "myasBook"] == "" } {
  210.       setCamera "bookCornerNotesTaken"
  211.       wizhCameraChange
  212.       freezePlayer
  213.       
  214.       chainEvent { delay 500 }
  215.       
  216.       callEvent "bookCornerBehavior"
  217.  
  218.     } elseif { [getVar "bookCornerBehavior"] == "ok" || [getVar "myasBook"] == "ok" || [getVar "lostBook"] == "ok" } {
  219.       setCamera "bookCornerNotesTaken"
  220.       wizhCameraChange
  221.  
  222.     } else {
  223.       setCamera "bookCornerNotesTaken"
  224.       wizhCameraChange
  225.     }
  226.   }
  227. }
  228.  
  229.  
  230. ## ===================================================== ##
  231. ##   corridor Camera                                     ##
  232. ## ===================================================== ##
  233.  
  234. event "corridor" {
  235.   wizEntityResumeFollow Zak
  236.   setCamera "corridor"
  237.   wizhCameraChange
  238. }
  239.  
  240.  
  241. ################################################################################
  242. ## ========================================================================== ##
  243. ##   NPC DIALOGUE SECTION                                                     ##
  244. ## ========================================================================== ##
  245. ################################################################################
  246.  
  247.  
  248. # NONE FOR NOW
  249.  
  250.  
  251. ################################################################################
  252. ## ========================================================================== ##
  253. ##   FORCED DIALOGUE SECTION                                                  ##
  254. ## ========================================================================== ##
  255. ################################################################################
  256.  
  257.  
  258. ## ===================================================== ##
  259. ##   The Lost Notebook                                   ##
  260. ## ===================================================== ##
  261. ## Trigger is when the player get the Notebook Alone.
  262.  
  263. event "lostBook" {
  264.   checkConversation "lostBook" {
  265.  
  266.     chainEvent {
  267.       freezePlayer
  268.       wizDisableFloorevent
  269.       wizDisableMouse
  270.     }
  271.  
  272.     ozSet "itemNoteBook" "pickedUp"
  273.     ozSet "magicalDocuments" "pickedUp"
  274.  
  275.     # Block 1
  276.     wizqQueue 1 {
  277.       chainEvent { delay 3000 }
  278.       ozqSound::NewFX  "sound/sfx/zakBookPickup.ogg"
  279.       chainEvent { setCrossfadeCamera "notebookCloseUpNotesTaken" }
  280.     }
  281.  
  282.     wizqTalkOpen
  283.     wizqTalkSay Lydia $::lng::myasBookL1   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL1.ogg"
  284.     wizqTalkSay Lydia $::lng::myasBookL2   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL2.ogg"
  285.  
  286.     # Wait for Block 1
  287.     wizqWaitQueue 1
  288.  
  289.     # Block 2
  290.     wizqQueue 1 {
  291.       chainEvent { standardFadeout }
  292.       chainEvent {
  293.         setCamera "bookCornerNotesTaken"
  294.         wizhCameraChange
  295.         SetModelLydia
  296.         wizEntityShow Lydia
  297.         hRemoveBack
  298.       }
  299.       wizqEntitySetCycle Lydia crouchCycleNormal
  300.       chainEvent {
  301.         standardFadein
  302.       }
  303.       wizqEntityChangeCycle Lydia standCycleNormal crouchToStand "wait"
  304.       chainEvent { delay 100 }
  305.       chainEvent { wizEntityLookAt Lydia "414.1 84.3 270.5" }
  306.       chainEvent { delay 500 }
  307.       wizqEntityAction Lydia standWhat "wait"
  308.     }
  309.  
  310.     wizqTalkSay Lydia $::lng::myasBookL3   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL3.ogg"
  311.  
  312.     # Wait for Block 2
  313.     wizqWaitQueue 1
  314.  
  315.     # Block 3
  316.     wizqQueue 1 {
  317.       chainEvent { delay 1000 }
  318.       wizqEntityWalk Lydia "411.7 84.3 274.4" "wait"
  319.       wizqEntityAction Lydia standHandOnChin "wait"
  320.     }
  321.  
  322.     wizqTalkSay Lydia $::lng::lostBookL1   "sound/vo/$::LNG/scenes/enchantedHallway/lostBookL1.ogg"
  323.  
  324.     # Wait for Block 3
  325.     wizqWaitQueue 1
  326.  
  327.     # Block 4
  328.     wizqQueue 1 {
  329.       wizqEntityOrientation Lydia 80 "wait"
  330.       wizqEntitySetCycle Lydia standCycleNormal
  331.       chainEvent { delay 500 }
  332.       wizqEntityAction Lydia standYes "wait"
  333.       chainEvent { delay 500 }
  334.       wizqEntityAction Lydia standDisbelief "wait"
  335.     }
  336.  
  337.     wizqTalkSay Lydia $::lng::lostBookL2   "sound/vo/$::LNG/scenes/enchantedHallway/lostBookL2.ogg"
  338.     wizqTalkSay Lydia $::lng::lostBookL3   "sound/vo/$::LNG/scenes/enchantedHallway/lostBookL3.ogg"
  339.     wizqTalkClose
  340.  
  341.     # Wait for Block 4
  342.     wizqWaitQueue 1
  343.  
  344.     chainEvent {
  345.       unfreezePlayer
  346.       wizEnableFloorevent
  347.       wizEnableMouse
  348.       wizEntityResumeFollow Zak
  349.     }
  350.  
  351.     chainEvent {
  352.       ozqSound::NewFX  "sound/interface/itemPickUp.ogg"
  353.       iq'showdesc noteBook
  354.     }
  355.   }
  356. }
  357.  
  358.  
  359. ## ===================================================== ##
  360. ##   Mya's Notebook                                      ##
  361. ## ===================================================== ##
  362. ## Trigger is when the player get the Notebook with Zak.
  363.  
  364. event "myasBook" {
  365.   checkConversation "myasBook" {
  366.     chainEvent {
  367.       wizEntityStopFollow Zak
  368.       freezePlayer
  369.       wizDisableFloorevent
  370.       wizDisableMouse
  371.     }
  372.  
  373.     ozSet "itemNoteBook" "pickedUp"
  374.     ozSet "magicalDocuments" "pickedUp"
  375.  
  376.     # Block 1
  377.     wizqQueue 1 {
  378.       chainEvent { oz'track::play $::music_track "sound/music/zakBook.ogg" }
  379.       chainEvent { delay 3000 }
  380.       ozqSound::NewFX  "sound/sfx/zakBookPickup.ogg"
  381.       chainEvent { setCrossfadeCamera "notebookCloseUpNotesTaken" }
  382.     }
  383.  
  384.     wizqTalkOpen
  385.     wizqTalkSay Lydia $::lng::myasBookL1   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL1.ogg"
  386.     wizqTalkSay Lydia $::lng::myasBookL2   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL2.ogg" fastout
  387.  
  388.     # Wait for Block 1
  389.     wizqWaitQueue 1
  390.  
  391.     # Block 2
  392.     wizqQueue 1 {
  393.       chainEvent { standardFadeout }
  394.       wizqEntitySetCycle Zak sitCycleNormal
  395.       chainEvent {
  396.         setCamera "bookCornerNotesTaken"
  397.         wizhCameraChange
  398.         wizEntityShow Lydia
  399.         wizEntityShow Zak
  400.         SetModelLydia
  401.         hRemoveBack
  402.       }
  403.       wizqEntitySetCycle Lydia crouchCycleNormal
  404.       chainEvent {
  405.         standardFadein
  406.       }
  407.       wizqEntityChangeCycle Lydia standCycleNormal crouchToStand "wait"
  408.       chainEvent { delay 100 }
  409.       chainEvent { wizEntityLookAt Lydia [wizEntityGetPosition Zak] }
  410.       chainEvent { delay 2500 }
  411.       wizqEntityAction Lydia standHandOnChin
  412.     }
  413.  
  414.     # Block 2-B
  415.     wizqQueue 2 {
  416.       chainEvent { wizEntitySetPosition Zak "413.1 84.3 274.7" }
  417.       chainEvent { wizEntityLookAt Zak [wizEntityGetPosition Lydia] }
  418.       chainEvent { delay 1500 }
  419.       wizqEntityAction Zak sitConfusedLeft "wait"
  420.     }
  421.  
  422.     wizqTalkSay Zak $::lng::myasBookZ1   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ1.ogg" fastin
  423.  
  424.     # Wait for Block 3-B
  425.     wizqWaitQueue 2
  426.  
  427.     # Block 3-B
  428.     wizqQueue 2 {
  429.       chainEvent { delay 500 }
  430.       wizqEntityAction Zak sitYes "wait"
  431.     }
  432.  
  433.     wizqTalkSay Zak $::lng::myasBookZ2   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ2.ogg"
  434.  
  435.     # Wait for Block 2 and 3-B
  436.     wizqWaitQueue 1
  437.     wizqWaitQueue 2
  438.  
  439.     # Block 3
  440.     wizqQueue 1 {
  441.       wizqEntityAction Lydia standTalkHandHip "wait"
  442.       wizqEntityAction Lydia standWhat
  443.     }
  444.     
  445.     # Block 3-B
  446.     wizqQueue 2 {
  447.       chainEvent { delay 1500 }
  448.       wizqEntityAction Zak sitScratch "wait"
  449.     }
  450.     
  451.     wizqTalkSay Lydia $::lng::myasBookL3   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL3.ogg"
  452.  
  453.     # Wait for Block 3 & 3-B
  454.     wizqWaitQueue 1
  455.     wizqWaitQueue 2
  456.  
  457.     # Block 4
  458.     wizqQueue 1 {
  459.       chainEvent { delay 1000 }
  460.       wizqEntitySetCycle Zak standCycleNormal
  461.       chainEvent { delay 2000 }
  462.       wizqEntityWalk Zak "404 84.3 265" "wait"
  463.       chainEvent { wizEntityLookAt Zak [wizEntityGetPosition Lydia] }
  464.       wizqEntityAction Zak standRelax "wait"
  465.     }
  466.     
  467.     # Block 4-B
  468.     wizqQueue 2 {
  469.       wizqEntitySetOrientationTarget Lydia Zak
  470.     }
  471.  
  472.     wizqTalkSay Zak $::lng::myasBookZ3   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ3.ogg"
  473.     wizqTalkSay Zak $::lng::myasBookZ4   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ4.ogg"
  474.  
  475.     # Wait for Block 4 & 4-B
  476.     wizqWaitQueue 1
  477.     wizqWaitQueue 2
  478.     wizqEntitySetOrientationTarget Lydia None
  479.  
  480.     # Block 5
  481.     wizqQueue 1 {
  482.       wizqEntityAction Lydia standDisbelief "wait"
  483.       wizqEntityAction Lydia standWhat "wait"
  484.       wizqEntityAction Lydia standTalkTwoHands
  485.     }
  486.  
  487.     wizqTalkSay Lydia $::lng::myasBookL4   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL4.ogg"
  488.     wizqTalkSay Lydia $::lng::myasBookL5   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL5.ogg"
  489.  
  490.     # Wait for Block 5
  491.     wizqWaitQueue 1
  492.  
  493.     # Block 6
  494.     wizqQueue 1 {
  495.       wizqEntityWalk Zak "394.3 84.5 263" "wait"
  496.       wizqEntitySetCycle Zak sitCycleNormal
  497.       chainEvent { delay 1000 }
  498.       wizqEntityAction Zak sitNo "wait"
  499.     }
  500.  
  501.     wizqTalkSay Zak $::lng::myasBookZ5   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ5.ogg"
  502.  
  503.     # Wait for Block 6
  504.     wizqWaitQueue 1
  505.  
  506.     if { [getVar "itemCirclet"] == "pickedUp" } {
  507.       # Block 7
  508.       wizqQueue 1 {
  509.         wizqEntityAction Lydia standHandOnChin "wait"
  510.         chainEvent { delay 500 }
  511.         chainEvent { wizEntityLookAt Lydia [wizEntityGetPosition Zak] }
  512.         chainEvent { delay 1000 }
  513.         wizqEntityAction Lydia standTalkTwoHands "wait"
  514.       }
  515.  
  516.       wizqTalkSay Lydia $::lng::myasBookL7   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL7.ogg"
  517.       wizqTalkSay Lydia $::lng::myasBookL8   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL8.ogg"
  518.  
  519.       if { [getVar "potionMaking"] == "needed" || [getVar "potionMaking"] == "initiated" } {
  520.         wizqTalkSay Lydia $::lng::myasBookL9   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL9.ogg"
  521.         wizqTalkClose
  522.         
  523.       } else {
  524.         wizqTalkSay Lydia $::lng::myasBookL10   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL10.ogg"
  525.         wizqTalkClose
  526.       }
  527.  
  528.       # Wait for Block 7
  529.       wizqWaitQueue 1
  530.       
  531.     } else {
  532.     
  533.       # Block 7
  534.       wizqQueue 1 {
  535.         chainEvent { delay 500 }
  536.         wizqEntityAction Lydia standDisbelief "wait"
  537.       }
  538.  
  539.       wizqTalkSay Lydia $::lng::myasBookL6   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL6.ogg"
  540.       wizqTalkClose
  541.     
  542.       # Wait for Block 7
  543.       wizqWaitQueue 1
  544.  
  545.       if { [getVar "whatLanguage"] == "" } {
  546.         setEventPriority optionnalConversation.whatLanguageBehavior medium
  547.         ozSet "whatLanguage" "initiated"
  548.       }
  549.     
  550.       if { [getVar "whatIsWritten"] == "" } {
  551.         setEventPriority optionnalConversation.whatIsWrittenBehavior medium
  552.         ozSet "whatIsWritten" "initiated"
  553.       }
  554.     }
  555.   
  556.     if { [ozGet "nbPage"] == "first" || [ozGet "nbPage"] == "second" } {
  557.       # Block 8
  558.       wizqQueue 1 {
  559.         chainEvent { delay 1500 }
  560.         wizqEntityAction Lydia standYes "wait"
  561.       }
  562.  
  563.       wizqTalkOpen
  564.       wizqTalkSay Lydia $::lng::myasBookL11   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL11.ogg"
  565.       wizqTalkClose
  566.  
  567.     } elseif { [ozGet "nbPage"] == "fullBook" } {
  568.       # Block 8
  569.       wizqQueue 1 {
  570.         chainEvent { delay 1500 }
  571.         wizqEntityAction Lydia standYes "wait"
  572.       }
  573.       
  574.       wizqTalkOpen
  575.       wizqTalkSay Lydia $::lng::myasBookL12   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL12.ogg"
  576.       wizqTalkClose
  577.     }
  578.  
  579.     # Wait for Block 8
  580.     wizqWaitQueue 1
  581.       
  582.     if { [getVar "itemCirclet"] == "pickedUp" && [getVar "potionPlease"] == "" } {
  583.       setEventPriority optionnalConversation.potionPlease medium
  584.       ozSet "potionPlease" "initiated"
  585.     }
  586.  
  587.     chainEvent {
  588.       ozqSound::NewFX  "sound/interface/itemPickUp.ogg"
  589.       iq'showdesc noteBook
  590.     }
  591.  
  592.     chainEvent {
  593.       unfreezePlayer
  594.       wizEnableFloorevent
  595.       wizEnableMouse
  596.     }
  597.   }
  598. }
  599.  
  600.  
  601. ## ===================================================== ##
  602. ##   Tale of a Notebook                                  ##
  603. ## ===================================================== ##
  604. ## Trigger is when the player pass here with Zak and got
  605. ## the Notebook before he free him.
  606.  
  607. event "bookCornerBehavior" {
  608.   # Zak and Lydia's conversation
  609.   checkConversation "bookCornerBehavior" {
  610.     chainEvent { oz'track::play $::music_track "sound/music/zakBook.ogg" }
  611.     chainEvent {
  612.       wizEntityStopFollow Zak
  613.       freezePlayer
  614.       wizDisableFloorevent
  615.       wizDisableMouse
  616.     }
  617.  
  618.     # Block 1
  619.     wizqQueue 1 {
  620.       wizqEntityWalk Lydia "407 84.3 281" "wait"
  621.       chainEvent { wizEntityLookAt Lydia "414.1 84.3 270.5" }
  622.       wizqEntitySetCycle Lydia standCycleNormal
  623.       wizqEntityAction Lydia standTalkHandHip
  624.     }
  625.  
  626.     # Block 1-B
  627.     wizqQueue 2 {
  628.       wizqEntityWalk Zak "414.1 84.3 270.5" "wait"
  629.       chainEvent { wizEntityLookAt Zak "407 84.3 281" }
  630.       chainEvent { delay 1000 }
  631.       wizqEntitySetCycle Zak sitCycleNormal
  632.       wizqEntityAction Zak standConfusedLeft "wait"
  633.     }
  634.  
  635.     wizqTalkOpen
  636.     wizqTalkSay Lydia $::lng::bookCornerBehaviorL1   "sound/vo/$::LNG/scenes/enchantedHallway/bookCornerBehaviorL1.ogg"
  637.  
  638.     # Wait for Block 1 & 1-B
  639.     wizqWaitQueue 1
  640.     wizqWaitQueue 2
  641.  
  642.     # Block 2
  643.     wizqQueue 1 {
  644.       wizqEntityChangeCycle Zak sitCycleNormal standToSit "wait"
  645.     }
  646.     
  647.     # Block 2-B
  648.     wizqQueue 2 {
  649.       chainEvent { delay 4000 }
  650.       wizqEntityAction Lydia standHandOnChin
  651.     }
  652.     
  653.     wizqTalkSay Zak $::lng::myasBookZ1   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ1.ogg"
  654.  
  655.     # Wait for Block 2
  656.     wizqWaitQueue 1
  657.     
  658.     # Block 3-B
  659.     wizqQueue 1 {
  660.       chainEvent { delay 500 }
  661.       wizqEntityAction Zak sitYes "wait"
  662.     }
  663.     
  664.     wizqTalkSay Zak $::lng::myasBookZ2   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ2.ogg"
  665.     
  666.     # Wait for Block 2 & 3-B
  667.     wizqWaitQueue 1
  668.     wizqWaitQueue 2
  669.  
  670.     # Block 3
  671.     wizqQueue 1 {
  672.       wizqEntityAction Lydia standTalkHandHip "wait"
  673.       wizqEntityAction Lydia standWhat
  674.     }
  675.  
  676.     # Block 3-B
  677.     wizqQueue 2 {
  678.       chainEvent { delay 1500 }
  679.       wizqEntityAction Zak sitScratch "wait"
  680.     }
  681.  
  682.     wizqTalkSay Lydia $::lng::myasBookL3   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL3.ogg"
  683.  
  684.     # Wait for Block 3 & 3-B
  685.     wizqWaitQueue 1
  686.     wizqWaitQueue 2
  687.  
  688.     # Block 4
  689.     wizqQueue 1 {
  690.       wizqEntitySetCycle Zak standCycleNormal
  691.       chainEvent { delay 2000 }
  692.       wizqEntityWalk Zak "404 84.3 265" "wait"
  693.       chainEvent { wizEntityLookAt Zak [wizEntityGetPosition Lydia] }
  694.       chainEvent { delay 10 }
  695.       wizqEntityAction Zak standRelax "wait"
  696.     }
  697.  
  698.     # Block 4-B
  699.     wizqQueue 2 {
  700.       chainEvent { delay 2000 }
  701.       wizqEntitySetOrientationTarget Lydia Zak
  702.     }
  703.  
  704.     wizqTalkSay Zak $::lng::myasBookZ3   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ3.ogg"
  705.     wizqTalkSay Zak $::lng::myasBookZ4   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ4.ogg"
  706.  
  707.     # Wait for Block 4 & 4-B
  708.     wizqWaitQueue 1
  709.     wizqWaitQueue 2
  710.     wizqEntitySetOrientationTarget Lydia None
  711.  
  712.     # Block 5
  713.     wizqQueue 1 {
  714.       wizqEntityAction Lydia standDisbelief "wait"
  715.       wizqEntityAction Lydia standWhat "wait"
  716.       wizqEntityAction Lydia standTalkTwoHands
  717.     }
  718.  
  719.     wizqTalkSay Lydia $::lng::myasBookL4   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL4.ogg"
  720.     wizqTalkSay Lydia $::lng::myasBookL5   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL5.ogg"
  721.  
  722.     # Wait for Block 5
  723.     wizqWaitQueue 1
  724.  
  725.  
  726.     # Block 6
  727.     wizqQueue 1 {
  728.       wizqEntityWalk Zak "394.3 84.5 263" "wait"
  729.       wizqEntitySetCycle Zak sitCycleNormal
  730.       chainEvent { delay 1000 }
  731.       wizqEntityAction Zak sitNo "wait"
  732.     }
  733.  
  734.     wizqTalkSay Lydia $::lng::myasBookZ5   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookZ5.ogg"
  735.  
  736.     # Wait for Block 6
  737.     wizqWaitQueue 1
  738.  
  739.     # Block 7
  740.     wizqQueue 1 {
  741.       chainEvent { delay 500 }
  742.       wizqEntityAction Lydia standDisbelief "wait"
  743.     }
  744.  
  745.     wizqTalkSay Lydia $::lng::myasBookL6   "sound/vo/$::LNG/scenes/enchantedHallway/myasBookL6.ogg"
  746.     wizqTalkClose
  747.  
  748.     # Wait for Block 7
  749.     wizqWaitQueue 1
  750.   }
  751.   
  752.   if { [getVar "whatLanguage"] == "" } {
  753.     setEventPriority optionnalConversation.whatLanguageBehavior medium
  754.     ozSet "whatLanguage" "initiated"
  755.   }
  756.  
  757.   if { [getVar "whatIsWritten"] == "" } {
  758.     setEventPriority optionnalConversation.whatIsWrittenBehavior medium
  759.     ozSet "whatIsWritten" "initiated"
  760.   }
  761.  
  762.   if { [getVar "itemNoteBook"] == "pickedUp" && [getVar "itemCirclet"] == "pickedUp" && [getVar "potionPlease"] == "" } {
  763.     setEventPriority optionnalConversation.potionPlease medium
  764.     ozSet "potionPlease" "initiated"
  765.   }
  766.  
  767.   chainEvent {
  768.     unfreezePlayer
  769.     wizEnableFloorevent
  770.     wizEnableMouse
  771.   }
  772. }
  773.  
  774.  
  775. ################################################################################
  776. ## ========================================================================== ##
  777. ##   OPTIONNAL DIALOGUE SECTION                                               ##
  778. ## ========================================================================== ##
  779. ################################################################################
  780.  
  781.  
  782. # NONE FOR NOW
  783.  
  784.  
  785. ################################################################################
  786. ## ========================================================================== ##
  787. ##   TO ADD/ CORRECTIONS NEEDED                                               ##
  788. ## ========================================================================== ##
  789. ################################################################################
  790.  
  791.  
  792. # NONE FOR NOW
  793.  
  794.  
  795. ################################################################################
  796. ## ========================================================================== ##
  797. ##   TO CHECK                                                                 ##
  798. ## ========================================================================== ##
  799. ################################################################################
  800.  
  801.  
  802. # NONE FOR NOW
  803.  
  804.  
  805.