home *** CD-ROM | disk | FTP | other *** search
/ Oz - The Magical Adventure / Adventure.iso / pc / dkdata / iceclimb.dxr / Internal_53_IceClimb_Inactivities.ls < prev    next >
Encoding:
Text File  |  2000-06-01  |  1.6 KB  |  56 lines

  1. on IceClimb_Inactivities
  2.   global gInactivities, gCurrentScreen, gCurrentSequence, gPlayOnly, gStartedPlaying, gJewelStatus
  3.   if value(gInactivities) = VOID then
  4.     gInactivities = "0"
  5.     if gStartedPlaying then
  6.       gInactivities = "1"
  7.     end if
  8.   end if
  9.   if voidp(gCurrentScreen) then
  10.     exit
  11.   end if
  12.   if not soundBusy(2) and (gCurrentSequence = "fee") then
  13.     gInactivities = string(value(gInactivities) + 1)
  14.     whichInactivity = value(gInactivities)
  15.     PromptList = EMPTY
  16.     theInactField = "iceClimb.inactivities"
  17.     if castExists(theInactField) then
  18.       PromptList = field(theInactField)
  19.     end if
  20.     if PromptList <> EMPTY then
  21.       PromptCount = PromptList.items.count
  22.       case whichInactivity of
  23.         2:
  24.           if (gJewelStatus = "111111111") and not gPlayOnly then
  25.             HostSound("6133")
  26.           else
  27.             HostSound("7531")
  28.           end if
  29.         3:
  30.           if gStartedPlaying then
  31.             whichPrompt = "754114"
  32.           else
  33.             whichPrompt = "7532"
  34.           end if
  35.         otherwise:
  36.           if whichInactivity > PromptCount then
  37.             whichInactivity = PromptCount - ((whichInactivity - PromptCount) mod 2)
  38.           end if
  39.           whichPrompt = item whichInactivity of PromptList
  40.       end case
  41.       if whichPrompt = "7533" then
  42.         if char 5 of gJewelStatus = "0" then
  43.           HostSound(whichPrompt)
  44.         else
  45.           HostSound("7531")
  46.         end if
  47.       else
  48.         HostSound(whichPrompt)
  49.       end if
  50.     end if
  51.     set the timeoutLength to 12 * 60
  52.   else
  53.     set the timeoutLength to 5 * 60
  54.   end if
  55. end
  56.