home *** CD-ROM | disk | FTP | other *** search
/ Blender Volume 3 #4 / Blender_3_4.iso / BLENDER / FILES / Shared.Cst / 00056.ls < prev    next >
Encoding:
Text File  |  1997-01-01  |  3.2 KB  |  104 lines

  1. --  Hi there all you Director freaks...
  2. --  The following scripts represent around 4 years of development & refinement 
  3. --  of our CDROM Magazine concept. However, as we're departing this compatibility nightmare
  4. --  land of CDROM for the bandwidth nightmare of the Web, we're probbly not going to be able use
  5. --  this code any more. So help yourselves. Sorry there's not more comments, and some is messy
  6. --  but it evolved under tight production deadlines and the influence of various substances.
  7. --  A special thanks to Dalya Ehrman, Mark Hammer, Tony Cruz, John Lounsbery, Damien Morton,
  8. --  Norman Douglas and Martine Moses for the elegant coding, and to Jamie Levy,  2chord, 
  9. --  Antenna, the writers of the bezier algorithm and the punch-out game for the inspiration...
  10. --  And of course my co-founder & friend, Jason Pearson, and our genius editor, Dale Hrabi.
  11. --
  12. --  Now get out there and make something. See you on the Web - www.blender.com.
  13. --  David Cherry 5/20/97
  14. --
  15. --  PS. Keep in mind that all the art/music/video on this disk etc is licenced by us for Blender. 
  16. --  If you rip it off & publish it, hell, we'll even help the copyright holders hunt you down.
  17.  
  18. global gOpSys -- the local operating system
  19.  
  20.  
  21. --PROCEDURES
  22.  
  23. on SPEAK
  24.   set the movieTime of sprite 40 to 0
  25.   set the movieRate of sprite 40 to 1.0
  26. end
  27.  
  28. --*************************************************************************--
  29.  
  30. on checkKey
  31.   if (the commandDown) and ((the key = "q") or (the key = "."))then 
  32.     endMOVIE
  33.   end if
  34. end checkKey
  35.  
  36. --*************************************************************************--
  37.  
  38. on switchVideo x
  39.   global cVID
  40.   if not the paramCount then set x = 0
  41.   set cVID = the castnum of sprite 40
  42.   if cVID > 0 then
  43.     if the castType of cast cVID = #digitalVideo then
  44.       set the movieRate of sprite 40 to x
  45.     end if
  46.   end if
  47. end switchVideo
  48.  
  49. --*************************************************************************--
  50.  
  51. on CLEANUP
  52.   global PSOUND
  53.   if PSOUND then
  54.     puppetSound PSOUND, 0
  55.     set PSOUND = 0
  56.   end if
  57.   if the paramCount then unPuppetVisPlus param(1)
  58.   else unPuppetVisPlus
  59.   switchVideo
  60.   checkMem
  61. end
  62.  
  63. --*************************************************************************--
  64.  
  65. on checkMem
  66.   global gMinimumRAM
  67.   if (the freeBlock/1024) < gMinimumRAM then unLoad
  68. end checkMem
  69.  
  70. --*************************************************************************--
  71.  
  72. on SETV x
  73.   global VOLUME
  74.   set VOLUME = x
  75.   set the soundlevel to x
  76. end
  77.  
  78. --*************************************************************************--
  79.  
  80. on unPuppetVisPlus myList
  81.   if not(the paramCount) then
  82.     repeat with n = 48 down to 1
  83.       puppetSprite n, 0
  84.       set the visible of sprite n to 1
  85.     end repeat
  86.   else
  87.     if getAt(myList, 1) < 0 then  
  88.       --negative values ie unpuppet everything but these
  89.       repeat with n = 1 to 48
  90.         if not getPos(myList, -n) then
  91.           puppetSprite n, 0
  92.           set the visible of sprite n to 1
  93.         end if
  94.       end repeat
  95.     else
  96.       repeat with n in myList  --positive values
  97.         puppetSprite n, 0
  98.         set the visible of sprite n to 1
  99.       end repeat
  100.     end if
  101.   end if
  102. end
  103. --*************************************************************************--
  104.