home *** CD-ROM | disk | FTP | other *** search
/ Discovering Nature in the City / LUONTOCD.iso / pc / files / main.dxr / 00001.ls next >
Encoding:
Text File  |  1996-12-17  |  7.7 KB  |  458 lines

  1. global gRollerList, gPreviousList, gFrom, gTo, gPath, gLanguage, gWinVersion, gMarker, pictureList, frameList, movieList, firstCharList, findMiaw, cameraMiaw, soundMiaw, toolMiaw
  2.  
  3. on startMovie
  4.   startTimer()
  5.   set x to gLanguage
  6.   set y to gWinVersion
  7.   set z to gMarker
  8.   set a to pictureList
  9.   set b to frameList
  10.   set c to movieList
  11.   set d to firstCharList
  12.   clearGlobals()
  13.   set gLanguage to x
  14.   set gWinVersion to y
  15.   set gMarker to z
  16.   set pictureList to a
  17.   set frameList to b
  18.   set movieList to c
  19.   set firstCharList to d
  20.   sound stop 1
  21.   puppetSound(0)
  22.   unLoad()
  23.   set the idleLoadMode to 3
  24.   set the preLoadEventAbort to 1
  25.   set gFrom to 15
  26.   set gTo to 29
  27.   set gRollerList to [31: member 49 of castLib "shared", 32: member 50 of castLib "shared", 34: member 21 of castLib "shared", 35: member 22 of castLib "shared", 36: member 23 of castLib "shared", 37: member 24 of castLib "shared", 38: member 25 of castLib "shared", 39: member 36 of castLib "shared"]
  28.   set gPreviousList to []
  29.   set gPath to the pathName
  30. end
  31.  
  32. on stopMovie
  33.   sound stop 1
  34.   set the volume of sound 1 to 255
  35. end
  36.  
  37. on nextFrame
  38.   go(the frame + 1)
  39. end
  40.  
  41. on previousFrame
  42.   go(the frame - 1)
  43. end
  44.  
  45. on goPrevious
  46.   set z to getLast(gPreviousList)
  47.   if voidp(z) then
  48.     go("main")
  49.   else
  50.     set x to count(gPreviousList)
  51.     deleteAt(gPreviousList, x)
  52.     set y to getLast(gPreviousList)
  53.     go(y)
  54.   end if
  55. end
  56.  
  57. on goStory
  58.   forgetWindows()
  59.   go("story1")
  60. end
  61.  
  62. on goPlus1
  63.   go(the frame + 1)
  64. end
  65.  
  66. on goToTest
  67.   forgetWindows()
  68.   go("test")
  69. end
  70.  
  71. on credits
  72.   sound stop 1
  73.   forgetWindows()
  74.   preLoad(550, 554)
  75.   go("credits")
  76.   set the volume of sound 1 to 255
  77.   sound playFile 1, gPath & "credits.aif"
  78.   updateStage()
  79. end
  80.  
  81. on svenska
  82.   cursor(4)
  83.   sound stop 1
  84.   set gLanguage to "swe"
  85.   forgetWindows()
  86.   go(1, "mainswe")
  87. end
  88.  
  89. on goTest
  90.   set the cursor of sprite the clickOn to 4
  91.   cursor(4)
  92.   case the clickOn of
  93.     "15":
  94.       go("test1")
  95.     "16":
  96.       go("test2")
  97.     "17":
  98.       go("test3")
  99.     "18":
  100.       go("test4")
  101.     "19":
  102.       go("test5")
  103.     "20":
  104.       go("test6")
  105.     "21":
  106.       go("test7")
  107.     "22":
  108.       go("test8")
  109.     "23":
  110.       go("test9")
  111.     "24":
  112.       go("test10")
  113.     "25":
  114.       go("test11")
  115.   end case
  116. end
  117.  
  118. on go1
  119.   set the cursor of sprite the clickOn to 4
  120.   go("urban")
  121. end
  122.  
  123. on go2
  124.   set the cursor of sprite the clickOn to 4
  125.   forgetWindows()
  126.   go(1, "@:game:game1")
  127. end
  128.  
  129. on go3
  130.   set the cursor of sprite the clickOn to 4
  131.   go("urban")
  132. end
  133.  
  134. on go4
  135.   set the cursor of sprite the clickOn to 4
  136.   go("urban")
  137. end
  138.  
  139. on go5
  140.   set the cursor of sprite the clickOn to 4
  141.   forgetWindows()
  142.   go(1, "board")
  143. end
  144.  
  145. on go6
  146.   set the cursor of sprite the clickOn to 4
  147.   go("animals")
  148. end
  149.  
  150. on go7
  151.   set the cursor of sprite the clickOn to 4
  152.   go("plants")
  153. end
  154.  
  155. on go8
  156.   set the cursor of sprite the clickOn to 4
  157.   go("mushroom")
  158. end
  159.  
  160. on go9
  161.   set the cursor of sprite the clickOn to 4
  162.   go("urban")
  163. end
  164.  
  165. on go10
  166.   set the cursor of sprite the clickOn to 4
  167.   go(1, "zoo")
  168. end
  169.  
  170. on go11
  171.   set the cursor of sprite the clickOn to 4
  172.   go("info")
  173. end
  174.  
  175. on go12
  176.   set the cursor of sprite the clickOn to 4
  177.   go("birds")
  178. end
  179.  
  180. on go13
  181.   set the cursor of sprite the clickOn to 4
  182.   go("mammals")
  183. end
  184.  
  185. on go14
  186.   set the cursor of sprite the clickOn to 4
  187.   go("inver")
  188. end
  189.  
  190. on go15
  191.   set the cursor of sprite the clickOn to 4
  192.   go("reptiles")
  193. end
  194.  
  195. on go16
  196.   set the cursor of sprite the clickOn to 4
  197.   go("mamm1")
  198. end
  199.  
  200. on go17
  201.   set the cursor of sprite the clickOn to 4
  202.   go("mamm2")
  203. end
  204.  
  205. on go18
  206.   set the cursor of sprite the clickOn to 4
  207.   go("mamm3")
  208. end
  209.  
  210. on go19
  211.   set the cursor of sprite the clickOn to 4
  212.   go("mamm4")
  213. end
  214.  
  215. on go20
  216.   set the cursor of sprite the clickOn to 4
  217.   go("mamm5")
  218. end
  219.  
  220. on go21
  221.   set the cursor of sprite the clickOn to 4
  222.   go("mamm6")
  223. end
  224.  
  225. on go22
  226.   set the cursor of sprite the clickOn to 4
  227.   go("bird1")
  228. end
  229.  
  230. on go23
  231.   set the cursor of sprite the clickOn to 4
  232.   go("bird2")
  233. end
  234.  
  235. on go24
  236.   set the cursor of sprite the clickOn to 4
  237.   go("bird3")
  238. end
  239.  
  240. on go25
  241.   set the cursor of sprite the clickOn to 4
  242.   go("bird4")
  243. end
  244.  
  245. on go26
  246.   set the cursor of sprite the clickOn to 4
  247.   go("bird5")
  248. end
  249.  
  250. on go27
  251.   set the cursor of sprite the clickOn to 4
  252.   go("bird6")
  253. end
  254.  
  255. on go28
  256.   set the cursor of sprite the clickOn to 4
  257.   go("bird7")
  258. end
  259.  
  260. on go29
  261.   set the cursor of sprite the clickOn to 4
  262.   go("bird8")
  263. end
  264.  
  265. on go30
  266.   set the cursor of sprite the clickOn to 4
  267.   go("inverA")
  268. end
  269.  
  270. on go31
  271.   set the cursor of sprite the clickOn to 4
  272.   go("inverB")
  273. end
  274.  
  275. on goInverA
  276.   set the cursor of sprite the clickOn to 4
  277.   cursor(4)
  278.   case the clickOn of
  279.     "15":
  280.       go("inverA1")
  281.     "16":
  282.       go("inverA2")
  283.     "17":
  284.       go("inverA3")
  285.     "18":
  286.       go("inverA4")
  287.     "19":
  288.       go("inverA5")
  289.   end case
  290. end
  291.  
  292. on goInverB
  293.   set the cursor of sprite the clickOn to 4
  294.   cursor(4)
  295.   case the clickOn of
  296.     "15":
  297.       go("inverB1")
  298.     "16":
  299.       go("inverB2")
  300.     "17":
  301.       go("inverB3")
  302.     "18":
  303.       go("inverB4")
  304.     "19":
  305.       go("inverB5")
  306.   end case
  307. end
  308.  
  309. on goReptiles
  310.   global gFrameLabel
  311.   set the cursor of sprite the clickOn to 4
  312.   cursor(4)
  313.   case the clickOn of
  314.     "15":
  315.       set gFrameLabel to "pic101"
  316.       go(1, "reptiles")
  317.     "16":
  318.       set gFrameLabel to "pic102"
  319.       go("pic102", "reptiles")
  320.     "17":
  321.       set gFrameLabel to "pic103"
  322.       go("pic103", "reptiles")
  323.     "18":
  324.       set gFrameLabel to "pic104"
  325.       go("pic104", "reptiles")
  326.     "19":
  327.       set gFrameLabel to "pic105"
  328.       go("pic105", "reptiles")
  329.     "20":
  330.       go(1, "reptiles")
  331.   end case
  332. end
  333.  
  334. on goPlantB
  335.   set the cursor of sprite the clickOn to 4
  336.   cursor(4)
  337.   case the clickOn of
  338.     "15":
  339.       go("plB1")
  340.     "16":
  341.       go("plB2")
  342.     "17":
  343.       go("plB3")
  344.     "18":
  345.       go("plQ")
  346.   end case
  347. end
  348.  
  349. on goPlantB1
  350.   set the cursor of sprite the clickOn to 4
  351.   cursor(4)
  352.   case the clickOn of
  353.     "15":
  354.       go("plant1")
  355.     "16":
  356.       go("plant2")
  357.     "17":
  358.       go("plant3")
  359.     "18":
  360.       go("plant4")
  361.   end case
  362. end
  363.  
  364. on goPlantB2
  365.   set the cursor of sprite the clickOn to 4
  366.   cursor(4)
  367.   case the clickOn of
  368.     "15":
  369.       go("plant5")
  370.     "16":
  371.       go("plant6")
  372.     "17":
  373.       go("plant7")
  374.     "18":
  375.       go("plant8")
  376.   end case
  377. end
  378.  
  379. on goPlantB3
  380.   set the cursor of sprite the clickOn to 4
  381.   cursor(4)
  382.   case the clickOn of
  383.     "15":
  384.       go("plant9")
  385.     "16":
  386.       go("plant10")
  387.     "17":
  388.       go("plant11")
  389.     "18":
  390.       go("plant12")
  391.   end case
  392. end
  393.  
  394. on goPlant1
  395.   global gFrameLabel
  396.   set the cursor of sprite the clickOn to 4
  397.   cursor(4)
  398.   case the clickOn of
  399.     "15":
  400.       set gFrameLabel to "pic101"
  401.       go(1, "plants")
  402.     "16":
  403.       set gFrameLabel to "pic102"
  404.       go("pic102", "plants")
  405.     "17":
  406.       set gFrameLabel to "pic103"
  407.       go("pic103", "plants")
  408.     "18":
  409.       set gFrameLabel to "pic104"
  410.       go("pic104", "plants")
  411.     "19":
  412.       set gFrameLabel to "pic105"
  413.       go("pic105", "plants")
  414.     "20":
  415.       set gFrameLabel to "pic106"
  416.       go("pic106", "plants")
  417.   end case
  418. end
  419.  
  420. on indexButton f, m
  421.   global gFrameLabel
  422.   set N to the clickOn
  423.   set the puppet of sprite N to 1
  424.   set H to the locH of sprite N
  425.   set V to the locV of sprite N
  426.   set the locH of sprite N to H + 2
  427.   set the locV of sprite N to V + 2
  428.   updateStage()
  429.   repeat while the mouseDown = 1
  430.     if rollOver(N) = 1 then
  431.       set the locH of sprite N to H + 2
  432.       set the locV of sprite N to V + 2
  433.       updateStage()
  434.       next repeat
  435.     end if
  436.     set the locH of sprite N to H
  437.     set the locV of sprite N to V
  438.     updateStage()
  439.   end repeat
  440.   set the locH of sprite N to H
  441.   set the locV of sprite N to V
  442.   updateStage()
  443.   set the puppet of sprite N to 0
  444.   if rollOver(N) = 1 then
  445.     puppetSprite(10, 1)
  446.     set the locV of sprite 10 to 192
  447.     updateStage()
  448.     set the cursor of sprite the clickOn to 4
  449.     cursor(4)
  450.     set gFrameLabel to f
  451.     do("go frame" && QUOTE & f & QUOTE && "of movie" && QUOTE & m & QUOTE)
  452.   end if
  453. end
  454.  
  455. on goSweBoard
  456.   go(1, "boardswe")
  457. end
  458.