home *** CD-ROM | disk | FTP | other *** search
/ What PC? 1997 February / WPCFEB97.ISO / multi / acacia / start.dxr / 00070.ls < prev    next >
Encoding:
Text File  |  1996-11-13  |  1.6 KB  |  60 lines

  1. on startMovie
  2.   global gAcaciaDown, gBiolDown, gChemDown, gPhysDown, gMathsDown, gQuitDown, gCD_Root, gPath, gDelim, gNewQnList
  3.   if the machineType = 256 then
  4.     set gDelim to "\"
  5.   else
  6.     set gDelim to ":"
  7.   end if
  8.   set gAcaciaDown to 0
  9.   set gBiolDown to 0
  10.   set gChemDown to 0
  11.   set gPhysDown to 0
  12.   set gMathsDown to 0
  13.   set gQuitDown to 0
  14.   set gCD_Root to the pathName
  15.   set gPath to the pathName
  16.   set gNewQnList to [:]
  17. end
  18.  
  19. on RunTest
  20.   global gTestList, gCursor, gCD_Root, gDelim
  21.   JumbleTest()
  22.   set next_qn to string(getPropAt(gTestList, gCursor))
  23.   if char 1 of next_qn = "2" then
  24.     go(1, gCD_Root & "BIOL" & gDelim & next_qn)
  25.   end if
  26.   if char 1 of next_qn = "8" then
  27.     go(1, gCD_Root & "BIOL" & gDelim & next_qn)
  28.   end if
  29.   if char 1 of next_qn = "3" then
  30.     go(1, gCD_Root & "CHEM" & gDelim & next_qn)
  31.   end if
  32.   if char 1 of next_qn = "7" then
  33.     go(1, gCD_Root & "CHEM" & gDelim & next_qn)
  34.   end if
  35.   if char 1 of next_qn = "4" then
  36.     if char 2 of next_qn = "5" then
  37.       go(1, gCD_Root & "SPACE" & gDelim & next_qn)
  38.     else
  39.       go(1, gCD_Root & "PHYS" & gDelim & next_qn)
  40.     end if
  41.   end if
  42.   if char 1 of next_qn = "6" then
  43.     go(1, gCD_Root & "PHYS" & gDelim & next_qn)
  44.   end if
  45. end
  46.  
  47. on JumbleTest
  48.   global gTestList
  49.   set holdlist to gTestList
  50.   set gTestList to [:]
  51.   set num to count(holdlist)
  52.   repeat with i = 1 to num
  53.     set thisone to random(count(holdlist))
  54.     set thisprop to getPropAt(holdlist, thisone)
  55.     set thisval to getAt(holdlist, thisone)
  56.     deleteAt(holdlist, thisone)
  57.     addProp(gTestList, thisprop, thisval)
  58.   end repeat
  59. end
  60.