home *** CD-ROM | disk | FTP | other *** search
/ PC Direct 1995 September / PCD0995.ISO / files / goer.dir / 00006.ls < prev    next >
Encoding:
Text File  |  1994-12-18  |  1.2 KB  |  42 lines

  1. on mouseDown
  2.   set WhichSprite to the clickOn
  3.   puppetSprite(WhichSprite, 1)
  4.   set the castNum of sprite WhichSprite to the number of cast "OK lit"
  5.   repeat while the stillDown
  6.     updateStage()
  7.   end repeat
  8. end
  9.  
  10. on mouseUp
  11.   global gMyPath, gPTimerSet, gPresentationTime, gPresentingTo, gLightColor
  12.   if the text of field "Timer Amount" = EMPTY then
  13.     alert("You need to enter a number into the Timer field!")
  14.     exit
  15.   end if
  16.   set whatTime to value(the text of field "Timer Amount")
  17.   if integerp(whatTime) then
  18.     startTimer()
  19.     set gPTimerSet to 1
  20.     set gPresentationTime to whatTime
  21.     set the timeoutLength to 3600 * whatTime
  22.     set gPresentingTo to the text of field "Who To"
  23.     set gLightColor to "Green timer light lit"
  24.     go(1, gMyPath & "intro")
  25.     exit
  26.   end if
  27.   if floatp(whatTime) then
  28.     startTimer()
  29.     set gPTimerSet to 1
  30.     set gPresentationTime to whatTime
  31.     set the timeoutLength to 3600 * whatTime
  32.     set gPresentingTo to the text of field "Who To"
  33.     set gLightColor to "Green timer light lit"
  34.     go(1, gMyPath & "intro")
  35.     exit
  36.   end if
  37.   alert("You need to enter a number greater than 2!")
  38.   set WhichSprite to the clickOn
  39.   puppetSprite(WhichSprite, 0)
  40.   set the castNum of sprite WhichSprite to the number of cast "OK"
  41. end
  42.