home *** CD-ROM | disk | FTP | other *** search
/ Shocking The Web CD-ROM / SHOCK_CD.ISO / pc / tutorial / casestdy / ch11_sfx / shabttxt.dir / 00001.ls next >
Encoding:
Text File  |  1996-11-12  |  1.0 KB  |  49 lines

  1. global gPlatform
  2.  
  3. on startMovie
  4.   clearGlobals()
  5.   set thisPage to "http://www.dxm.com/earshot" & "e_sabout.htm"
  6.   setShockSpec(thisPage)
  7.   localInit()
  8. end
  9.  
  10. on localInit
  11.   global gFields, showMe, gExitOp
  12.   setStyles()
  13.   initColorLists()
  14.   initHeightPatch()
  15.   set gFields to []
  16.   repeat with i = 1 to 5
  17.     append(gFields, "text" & i)
  18.   end repeat
  19.   resetAllFields()
  20.   set showMe to 0
  21.   set the randomSeed to the ticks
  22.   set gExitOp to " =" && QUOTE & "bold" & QUOTE && "then exit"
  23. end
  24.  
  25. on setShockSpec thisPage
  26.   if the machineType = 256 then
  27.     set gPlatform to "win"
  28.   else
  29.     set gPlatform to "mac"
  30.     if not (the colorDepth = 8) then
  31.       set the colorDepth to 8
  32.       WaitForTicks(30)
  33.       if not (the colorDepth = 8) then
  34.         alert("If possible, set your monitor to 256 colors and reload this page")
  35.         exit
  36.       else
  37.         GoToNetPage(thisPage)
  38.       end if
  39.     end if
  40.   end if
  41. end
  42.  
  43. on WaitForTicks theTicks
  44.   set startTime to the timer
  45.   repeat while (startTime + theTicks) > the timer
  46.     nothing()
  47.   end repeat
  48. end
  49.