home *** CD-ROM | disk | FTP | other *** search
/ GameStar 2004 January / Gamestar_58_2004-01_dvd.iso / setup1.cab / _00_01_Tutorial_2_1900.txt < prev    next >
Text File  |  2002-05-27  |  20KB  |  757 lines

  1. // ============================================================================
  2. // TUTORIAL 2
  3. // 
  4. // The script implements tutorial nr 2.
  5. //
  6. // Topic :
  7. //     - Building complex production
  8. //  - Playing with production parameters
  9. // ============================================================================
  10.  
  11. // ============================================================================
  12. // VARIABLES
  13. // ============================================================================
  14.     
  15. [VARIABLES]
  16.     
  17.     // Parameter variables.
  18.     ReturnState$
  19.     FirstTutorialTextID
  20.     LastTutorialTextID
  21.     TutorialTextID
  22.  
  23.     // Helper variables.
  24.     Local_i
  25.  
  26.     // Building IDs
  27.     ShopID
  28.     BuildingFactoryID
  29.     MineID
  30.     StoragePlace1ID
  31.     SteelMillID
  32.     LoggingCampID
  33.     SawMillID
  34.     StoragePlace2ID
  35.  
  36.     // Production IDs
  37.     MineProductionSet
  38.     SteelMillProductionSet
  39.     LoggingCampProductionSet
  40.     SawMillProductionSet
  41.  
  42. // ============================================================================
  43. // INIT
  44. // ============================================================================
  45. [STATE Load]
  46.  
  47.     LoadGame("missions\\00_01_Tutorial 2_1900.ig2")
  48.     LoadMissionConfig("missions\\00_01_Tutorial 2_1900.mis")
  49.     SetOutputMode(2)
  50.     SetMsgFilter(65535)
  51.     StartCommandFiltering()
  52.     ControlBar.SetDisable(871)
  53.     DialogControl.SetDisable(20)
  54.     ShopID = 733
  55.     BuildingFactoryID = 734
  56.     MineProductionSet = 0
  57.     SteelMillProductionSet = 0
  58.     LoggingCampProductionSet = 0
  59.     SawMillProductionSet = 0
  60.     Time.SetPace(1)
  61.     SetState("Intro")
  62.  
  63.  
  64. // ============================================================================
  65. // INTRO
  66. // ============================================================================
  67. [STATE Intro]
  68.  
  69.     FirstTutorialTextID = 350
  70.     LastTutorialTextID  = 352
  71.     ReturnState = 'SelectMine'
  72.     SetState("Show_tutorial_text_serie")
  73.  
  74. // ============================================================================
  75. // BUILD MINE
  76. // ============================================================================
  77. [STATE SelectMine]       
  78.     TutorialTextID = 302
  79.     ReturnState = 'WaitForSelectMine'
  80.     SetState("Show_tutorial_text")
  81.  
  82.  
  83. [STATE WaitForSelectMine]
  84.     IF BuildDialog.IsOpen() == 1 AND
  85.         BuildDialog.GetPanelID() == 1 AND
  86.         BuildDialog.GetSelectionID() == 0
  87.     THEN 
  88.         SetState("BuildMine")
  89.     END
  90.  
  91. [STATE BuildMine]
  92.     
  93.     TutorialTextID = 303
  94.     ReturnState = 'WaitForBuildMine'
  95.     SetState("Show_tutorial_text")
  96.  
  97. [STATE WaitForBuildMine]
  98.     IF IsEnterState
  99.     THEN
  100.         ClearCommandQueue()
  101.     END
  102.  
  103.     // Is there a queued command ? 
  104.     IF GetCommandQueueLength() > 0
  105.     THEN
  106.         IF NextCommand.GetType() == 4 AND
  107.             NextCommand.GetInternType() == 0
  108.  
  109.         THEN    
  110.             NextCommand.Run()
  111.             MineID = User.GetLastBuildingBuilt()
  112.             ClearCommandQueue()
  113.             SetState("BuildStoragePlace1")
  114.         ELSE
  115.             NextCommand.Cancel()
  116.             ClearCommandQueue()
  117.             SetState("BuildMine")
  118.         END
  119.     ELSE
  120.         IF BuildDialog.IsOpen() <> 1 OR
  121.             BuildDialog.GetPanelID() <> 1 OR
  122.             BuildDialog.GetSelectionID() <> 0
  123.         THEN 
  124.             SetState("SelectMine")
  125.         END
  126.     END
  127.  
  128.  
  129. // ============================================================================
  130. // BUILD STORAGE PLACE 1
  131. // ============================================================================
  132. [STATE BuildStoragePlace1]
  133.     
  134.     TutorialTextID = 306
  135.     ReturnState = 'WaitForStoragePlace1'
  136.     SetState("Show_tutorial_text")
  137.  
  138. [STATE WaitForStoragePlace1]
  139.     IF IsEnterState
  140.     THEN
  141.         ClearCommandQueue()
  142.     END
  143.  
  144.     // Is there a queued command ? 
  145.     IF GetCommandQueueLength() > 0
  146.     THEN
  147.         IF NextCommand.GetType() == 7
  148.         THEN    
  149.             SetState("VerifyForStoragePlace1Location")
  150.         ELSE
  151.             NextCommand.Cancel()
  152.             ClearCommandQueue()
  153.             SetState("BuildStoragePlace1")
  154.         END
  155.     END
  156.  
  157. [STATE VerifyForStoragePlace1Location]
  158.     IF IsHighlighted(BuildingFactoryID) AND
  159.         IsHighlighted(MineID)
  160.     THEN
  161.         NextCommand.Run()
  162.         StoragePlace1ID = User.GetLastBuildingBuilt()
  163.         ClearCommandQueue()
  164.         SetState("BuildSteelMill")
  165.     ELSE
  166.         TutorialTextID = 400
  167.         ReturnState = 'WaitForStoragePlace1'
  168.         SetState("Show_tutorial_text")
  169.     END
  170.  
  171.  
  172. // ============================================================================
  173. // SET MINE PRODUCTION
  174. // ============================================================================
  175. [STATE SetMineProduction]
  176.     
  177.     TutorialTextID = 309
  178.     ReturnState = 'WaitForMineProduction'
  179.     SetState("Show_tutorial_text")
  180.  
  181. [STATE WaitForMineProduction]
  182.     // Is there a queued command ? 
  183.     IF GetCommandQueueLength() > 0
  184.     THEN
  185.         IF NextCommand.GetType() == 14
  186.         THEN    
  187.             SetState("Verify_mine_production")
  188.         ELSE
  189.             NextCommand.Cancel()
  190.             ClearCommandQueue()
  191.             SetState("SetMineProduction")
  192.         END
  193.     END
  194.  
  195. [STATE Verify_mine_production]
  196.     // Is it correct product & load ?
  197.     IF NextCommand.GetInternType() == 0 AND
  198.         NextCommand.GetInternType2() == 0.25
  199.     THEN
  200.         MineProductionSet = 1
  201.         NextCommand.Run()
  202.         ClearCommandQueue()
  203.         SetState("SetSteelMillProduction")
  204.               
  205.     ELSE
  206.         NextCommand.Cancel()
  207.         ClearCommandQueue()
  208.         SetState("SetMineProduction")
  209.     END
  210.  
  211.  
  212. // ============================================================================
  213. // BUILD STEEL MILL
  214. // ============================================================================
  215. [STATE BuildSteelMill]
  216.     
  217.     TutorialTextID = 307
  218.     ReturnState = 'WaitForSteelMill'
  219.     SetState("Show_tutorial_text")
  220.  
  221. [STATE WaitForSteelMill]
  222.     IF IsEnterState
  223.     THEN
  224.         ClearCommandQueue()
  225.     END
  226.  
  227.     // Is there a queued command ? 
  228.     IF GetCommandQueueLength() > 0
  229.     THEN
  230.         IF NextCommand.GetType() == 4 AND
  231.             NextCommand.GetInternType() == 10
  232.         THEN    
  233.             SetState("VerifySteelMillLocation")
  234.         ELSE
  235.             NextCommand.Cancel()
  236.             ClearCommandQueue()
  237.             SetState("BuildSteelMill")
  238.         END
  239.     END
  240.  
  241. [STATE VerifySteelMillLocation]
  242.     IF IsHighlighted(StoragePlace1ID)
  243.     THEN
  244.         NextCommand.Run()
  245.         SteelMillID = User.GetLastBuildingBuilt()
  246.         ClearCommandQueue()
  247.         SetState("SetMineProduction")
  248.     ELSE
  249.         TutorialTextID = 401
  250.         ReturnState = 'WaitForSteelMill'
  251.         SetState("Show_tutorial_text")
  252.     END
  253.  
  254.  
  255. // ============================================================================
  256. // SET STEEL MILL PRODUCTION
  257. // ============================================================================
  258. [STATE SetSteelMillProduction]
  259.     
  260.     TutorialTextID = 312
  261.     ReturnState = 'WaitForSteelMillProduction'
  262.     SetState("Show_tutorial_text")
  263.  
  264. [STATE WaitForSteelMillProduction]
  265.     // Is there a queued command ? 
  266.     IF GetCommandQueueLength() > 0
  267.     THEN
  268.         IF NextCommand.GetType() == 14
  269.         THEN    
  270.             SetState("Verify_steel_mill_production")
  271.         ELSE
  272.             NextCommand.Cancel()
  273.             ClearCommandQueue()
  274.             SetState("SetSteelMillProduction")
  275.         END
  276.     END
  277.  
  278. [STATE Verify_steel_mill_production]
  279.     // Is it correct product & load ?
  280.     IF NextCommand.GetInternType() == 23 AND
  281.         NextCommand.GetInternType2() == 0.50
  282.     THEN
  283.         SteelMillProductionSet = 1
  284.         NextCommand.Run()
  285.         ClearCommandQueue()
  286.         SetState("BuildLoggingCamp")
  287.     ELSE
  288.         NextCommand.Cancel()
  289.         ClearCommandQueue()
  290.         SetState("SetSteelMillProduction")
  291.     END
  292.  
  293.  
  294. // ============================================================================
  295. // BUILD LOGGING CAMP
  296. // ============================================================================
  297. [STATE BuildLoggingCamp]
  298.     
  299.     TutorialTextID = 318
  300.     ReturnState = 'WaitForLoggingCamp'
  301.     SetState("Show_tutorial_text")
  302.  
  303. [STATE WaitForLoggingCamp]
  304.     IF IsEnterState
  305.     THEN
  306.         ClearCommandQueue()
  307.     END
  308.  
  309.     // Is there a queued command ? 
  310.     IF GetCommandQueueLength() > 0
  311.     THEN
  312.         IF NextCommand.GetType() == 4 AND
  313.             NextCommand.GetInternType() == 2
  314.         THEN    
  315.             SetState("VerifyLoggingCampLocation")
  316.         ELSE
  317.             NextCommand.Cancel()
  318.             ClearCommandQueue()
  319.             SetState("BuildLoggingCamp")
  320.         END
  321.     END
  322.  
  323. [STATE VerifyLoggingCampLocation]
  324.     IF IsHighlighted(StoragePlace1ID)
  325.     THEN
  326.         NextCommand.Run()
  327.         LoggingCampID = User.GetLastBuildingBuilt()
  328.         ClearCommandQueue()
  329.         SetState("BuildSawMill")
  330.     ELSE
  331.         TutorialTextID = 401
  332.         ReturnState = 'WaitForLoggingCamp'
  333.         SetState("Show_tutorial_text")
  334.     END
  335.  
  336.  
  337. // ============================================================================
  338. // SET LOGGING CAMP PRODUCTION
  339. // ============================================================================
  340. [STATE SetLoggingCampProduction]
  341.     
  342.     TutorialTextID = 327
  343.     ReturnState = 'WaitForLoggingCampProduction'
  344.     SetState("Show_tutorial_text")
  345.  
  346. [STATE WaitForLoggingCampProduction]
  347.     // Is there a queued command ? 
  348.     IF GetCommandQueueLength() > 0
  349.     THEN
  350.         IF NextCommand.GetType() == 14
  351.         THEN    
  352.             SetState("Verify_logging_camp_production")
  353.         ELSE
  354.             NextCommand.Cancel()
  355.             ClearCommandQueue()
  356.             SetState("SetLoggingCampProduction")
  357.         END
  358.     END
  359.  
  360. [STATE Verify_logging_camp_production]
  361.     // Is it correct product & load ?
  362.     IF NextCommand.GetInternType() == 7 AND
  363.         NextCommand.GetInternType2() == 0.25
  364.     THEN
  365.         LoggingCampProductionSet = 1
  366.         NextCommand.Run()
  367.         ClearCommandQueue()
  368.         SetState("SetSawMillProduction")
  369.     ELSE
  370.         NextCommand.Cancel()
  371.         ClearCommandQueue()
  372.         SetState("SetLoggingCampProduction")
  373.     END
  374.  
  375.  
  376. // ============================================================================
  377. // BUILD SAW MILL
  378. // ============================================================================
  379. [STATE BuildSawMill]
  380.     
  381.     TutorialTextID = 324
  382.     ReturnState = 'WaitForSawMill'
  383.     SetState("Show_tutorial_text")
  384.  
  385. [STATE WaitForSawMill]
  386.     IF IsEnterState
  387.     THEN
  388.         ClearCommandQueue()
  389.     END
  390.  
  391.     // Is there a queued command ? 
  392.     IF GetCommandQueueLength() > 0
  393.     THEN
  394.         IF NextCommand.GetType() == 4 AND
  395.             NextCommand.GetInternType() == 9
  396.         THEN    
  397.             SetState("VerifySawMillLocation")
  398.         ELSE
  399.             NextCommand.Cancel()
  400.             ClearCommandQueue()
  401.             SetState("BuildSawMill")
  402.         END
  403.     END
  404.  
  405. [STATE VerifySawMillLocation]
  406.     IF IsHighlighted(StoragePlace1ID)
  407.     THEN
  408.         NextCommand.Run()
  409.         SawMillID = User.GetLastBuildingBuilt()
  410.         ClearCommandQueue()
  411.         SetState("SetLoggingCampProduction")
  412.     ELSE
  413.         TutorialTextID = 401
  414.         ReturnState = 'WaitForSawMill'
  415.         SetState("Show_tutorial_text")
  416.     END
  417.  
  418.  
  419. // ============================================================================
  420. // SET SAW MILL PRODUCTION
  421. // ============================================================================
  422. [STATE SetSawMillProduction]
  423.     
  424.     TutorialTextID = 328
  425.     ReturnState = 'WaitForSawMillProduction'
  426.     SetState("Show_tutorial_text")
  427.  
  428. [STATE WaitForSawMillProduction]
  429.     // Is there a queued command ? 
  430.     IF GetCommandQueueLength() > 0
  431.     THEN
  432.         IF NextCommand.GetType() == 14
  433.         THEN    
  434.             SetState("Verify_saw_mill_production")
  435.         ELSE
  436.             NextCommand.Cancel()
  437.             ClearCommandQueue()
  438.             SetState("SetSawMillProduction")
  439.         END
  440.     END
  441.  
  442. [STATE Verify_saw_mill_production]
  443.     // Is it correct product & load ?
  444.     IF NextCommand.GetInternType() == 21 AND
  445.         NextCommand.GetInternType2() == 0.50
  446.     THEN
  447.         NextCommand.Run()
  448.         ClearCommandQueue()
  449.         SetState("StoragePlaceSettings")
  450.     ELSE
  451.         NextCommand.Cancel()
  452.         ClearCommandQueue()
  453.         SetState("SetSawMillProduction")
  454.     END
  455.  
  456. // ============================================================================
  457. // STORAGE PLACE SETTINGS
  458. // ============================================================================
  459. [STATE StoragePlaceSettings]
  460.     
  461.     TutorialTextID = 330
  462.     ReturnState = 'WaitForStoragePlaceDlg'
  463.     SetState("Show_tutorial_text")
  464.  
  465. [STATE WaitForStoragePlaceDlgClose]
  466.     IF StorageDialog.IsOpen() == 0 
  467.     THEN
  468.         SetState("StoragePlaceSettings")
  469.     ELSE
  470.         IF StorageDialog.GetStoragePlaceID() == StoragePlace1ID
  471.         THEN
  472.             SetState("WaitForStoragePlaceDlg")
  473.         END
  474.     END
  475.  
  476. [STATE WaitForStoragePlaceDlg]
  477.  
  478.     IF StorageDialog.IsOpen() == 1 
  479.     THEN
  480.         IF StorageDialog.GetStoragePlaceID() <> StoragePlace1ID
  481.         THEN
  482.             TutorialTextID = 330
  483.             ReturnState = 'WaitForStoragePlaceDlgClose'
  484.             SetState("Show_tutorial_text")
  485.         ELSE
  486.             FirstTutorialTextID = 331
  487.             LastTutorialTextID  = 333
  488.             ReturnState = 'WaitForBuildingMaterialIndustry'
  489.             SetState("Show_tutorial_text_serie")
  490.         END
  491.     END
  492.  
  493. [STATE WaitForBuildingMaterialIndustry]
  494.  
  495.     IF StorageDialog.GetCategory() == 19 AND
  496.         StorageDialog.GetLevel(73) == 0
  497.     THEN
  498.         TutorialTextID = 335
  499.         ReturnState = 'WaitForDialogAccept'
  500.         SetState("Show_tutorial_text")
  501.     ELSE
  502.         IF StorageDialog.IsOpen() == 0
  503.         THEN
  504.             SetState("StoragePlaceSettings")
  505.         END
  506.     END
  507.  
  508. [STATE WaitForLevel]
  509.     IF StorageDialog.GetLevel(73) == 0
  510.     THEN
  511.         TutorialTextID = 339
  512.         ReturnState = 'WaitForDialogAccept'
  513.         SetState("Show_tutorial_text")
  514.     ELSE
  515.         IF StorageDialog.IsOpen() == 0
  516.         THEN 
  517.             SetState("StoragePlaceSettings")
  518.         ELSE
  519.             IF StorageDialog.GetCategory() <> 19
  520.             THEN
  521.                 SetState("WaitForStoragePlaceDlg")
  522.             END
  523.         END
  524.     END
  525.  
  526.  
  527. [STATE WaitForDialogAccept]
  528.     IF IsEnterState
  529.     THEN
  530.         ClearCommandQueue()
  531.     END
  532.  
  533.     // Is there a queued command ? 
  534.     IF GetCommandQueueLength() > 0
  535.     THEN
  536.         IF NextCommand.GetType() == 31
  537.         THEN    
  538.             SetState("VerifyStoragePlaceSettings")
  539.         ELSE
  540.             NextCommand.Cancel()
  541.             ClearCommandQueue()
  542.             SetState("WaitForStoragePlaceDlg")
  543.         END
  544.     ELSE
  545.         IF StorageDialog.IsOpen() == 0
  546.         THEN
  547.             SetState("StoragePlaceSettings")
  548.         END
  549.     END
  550.  
  551. [STATE VerifyStoragePlaceSettings]
  552.     // Check the settings.
  553.     IF ChangeStoragePlace.GetProductLevel(0) == 0.25 AND
  554.         ChangeStoragePlace.GetProductLevel(7) == 0.25 AND
  555.         ChangeStoragePlace.GetProductLevel(21) == 0.25 AND
  556.         ChangeStoragePlace.GetProductLevel(23) == 0.25 AND
  557.         ChangeStoragePlace.GetProductLevel(73) == 0.0
  558.     THEN
  559.         NextCommand.Run()
  560.         SetState("SetBuildingFactoryProduction")
  561.     ELSE
  562.         SetState("StoragePlaceSettings")
  563.     END
  564.  
  565.  
  566. // ============================================================================
  567. // BUILD STORAGE PLACE 2
  568. // ============================================================================
  569. [STATE BuildStoragePlace2]
  570.     
  571.     TutorialTextID = 342
  572.     ReturnState = 'WaitForStoragePlace2'
  573.     SetState("Show_tutorial_text")
  574.  
  575. [STATE WaitForStoragePlace2]
  576.     IF IsEnterState
  577.     THEN
  578.         ClearCommandQueue()
  579.     END
  580.  
  581.     // Is there a queued command ? 
  582.     IF GetCommandQueueLength() > 0
  583.     THEN
  584.         IF NextCommand.GetType() == 7
  585.         THEN    
  586.             SetState("VerifyForStoragePlace2Location")
  587.         ELSE
  588.             NextCommand.Cancel()
  589.             ClearCommandQueue()
  590.             SetState("BuildStoragePlace2")
  591.         END
  592.     END
  593.  
  594. [STATE VerifyForStoragePlace2Location]
  595.     IF IsHighlighted(BuildingFactoryID) AND
  596.         IsHighlighted(ShopID)
  597.     THEN
  598.         NextCommand.Run()
  599.         StoragePlace2ID = User.GetLastBuildingBuilt()
  600.         ClearCommandQueue()
  601.         SetState("SetBuildingFactoryProduction")
  602.     ELSE
  603.         TutorialTextID = 403
  604.         ReturnState = 'WaitForStoragePlace2'
  605.         SetState("Show_tutorial_text")
  606.     END
  607.  
  608. // ============================================================================
  609. // CLICK ON FACTORY
  610. // ============================================================================
  611. [STATE ClickOnFactory]
  612.     TutorialTextID = 334
  613.     ReturnState = 'WaitForClickOnFactory'
  614.     SetState("Show_tutorial_text")
  615.  
  616. [STATE WaitForClickOnFactory]
  617.     IF ProductionDialog.IsOpen() == 1
  618.     THEN
  619.         SetState("Shops")
  620.     END
  621.   
  622.  
  623. // ============================================================================
  624. // SHOPS
  625. // ============================================================================
  626. [STATE Shops]
  627.     TutorialTextID = 335
  628.     ReturnState = 'WaitForShopDialog'
  629.     SetState("Show_tutorial_text")
  630.  
  631. [STATE WaitForShopDialog]
  632.     IF ShopDialog.IsOpen() == 1
  633.     THEN
  634.         TutorialTextID = 336
  635.         ReturnState = 'WaitForDemand'
  636.         SetState("Show_tutorial_text")    
  637.     END
  638.  
  639. [STATE WaitForDemand]
  640.     IF ShopDialog.IsOpen() == 0
  641.     THEN
  642.         SetState("Shops")
  643.     END
  644.  
  645.     IF ShopDialog.GetButtonPressed() == 2 AND
  646.         ShopDialog.GetProduct() == 73
  647.     THEN
  648.         SetState("SetBuildingFactoryProduction")
  649.     END
  650.  
  651.  
  652.  
  653. // ============================================================================
  654. // SET PRODUCTION
  655. // ============================================================================
  656. [STATE SetBuildingFactoryProduction]
  657.     
  658.     TutorialTextID = 336
  659.     ReturnState = 'WaitForBuildingFactoryProduction'
  660.     SetState("Show_tutorial_text")
  661.  
  662. [STATE WaitForBuildingFactoryProduction]
  663.     // Is there a queued command ? 
  664.     IF GetCommandQueueLength() > 0
  665.     THEN
  666.         IF NextCommand.GetType() == 14
  667.         THEN    
  668.             SetState("Verify_building_factory_production")
  669.         ELSE
  670.             NextCommand.Cancel()
  671.             ClearCommandQueue()
  672.             SetState("SetBuildingFactoryProduction")
  673.         END
  674.     END
  675.  
  676. [STATE Verify_building_factory_production]
  677.     // Is it correct product & load ?
  678.     IF NextCommand.GetInternType() == 73 
  679.     THEN
  680.         NextCommand.Run()
  681.         ClearCommandQueue()
  682.         SetState("ShowMissionGoal")
  683.     ELSE
  684.         NextCommand.Cancel()
  685.         ClearCommandQueue()
  686.         SetState("SetBuildingFactoryProduction")
  687.     END
  688.  
  689. // ============================================================================
  690. // MISSION GOAL
  691. // ============================================================================
  692. [STATE ShowMissionGoal]    
  693.     FirstTutorialTextID = 340
  694.     LastTutorialTextID  = 341
  695.     ReturnState = 'End'
  696.     SetState("Show_tutorial_text_serie")
  697.  
  698. // ============================================================================
  699. // END
  700. // ============================================================================
  701. [STATE End]
  702.  
  703.     IF IsEnterState
  704.     THEN
  705.         StopCommandFiltering()
  706.     END
  707.  
  708.     // Otherwise do nothing ... 
  709.  
  710.  
  711. // ============================================================================
  712. // HELPER STATES
  713. // 
  714. // Here are some states, which are used to do repetitive tasks.
  715. // ============================================================================
  716. //-----------------------------------------------------------------------------
  717. // Show_tutorial_text
  718. // - Opens tutorial text
  719. // - Waits until it is closed
  720. // - Returns to the return state
  721. // ----------------------------------------------------------------------------
  722. [STATE Show_tutorial_text]
  723.  
  724.     IF IsEnterState
  725.     THEN
  726.         TutorialText.Show(TutorialTextID)
  727.     ELSE
  728.         IF TutorialText.IsOpen() == 0
  729.         THEN 
  730.             SetState(ReturnState)
  731.         END
  732.     END
  733.  
  734. //-----------------------------------------------------------------------------
  735. // Show_tutorial_text_serie
  736. // - Shows a serie of tutorial texts from FirstTutorialTextID to LastTutorialTextID
  737. // ----------------------------------------------------------------------------
  738. [STATE Show_tutorial_text_serie]
  739.  
  740.     IF IsEnterState
  741.     THEN
  742.         Local_i = FirstTutorialTextID
  743.         TutorialText.Show(FirstTutorialTextID)
  744.     ELSE
  745.         IF TutorialText.IsOpen() == 0
  746.         THEN 
  747.             Local_i = Local_i + 1
  748.             
  749.             IF Local_i > LastTutorialTextID
  750.             THEN
  751.                 SetState(ReturnState)
  752.             ELSE
  753.                 TutorialText.Show(Local_i)
  754.             END
  755.         END
  756.     END
  757.