home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Boot Disc 2
/
boot-disc-1996-10.iso
/
Multimed.dir
/
00059_Script_59
< prev
next >
Wrap
Text File
|
1996-08-09
|
5KB
|
174 lines
on startmovie
resetAllText
end
on scroll delta,prefix
if voidP(prefix) then set prefix="d_"
set btnsprite=the clickon
set btn=the membernum of sprite btnsprite
set btndown=the number of member ((the name of member btn)&"Down")
puppetsprite btnsprite,true
set the membernum of sprite btnsprite to btndown
updateStage
repeat with index=1 to 48
set curcast=the membernum of sprite index
if curcast>0 then
if offset("d_",the name of member curcast)=1 then
set spritenum=index
exit repeat
end if
end if
end repeat
set pos=the scrolltop of member curcast
set textwidth=the bottom of sprite spritenum-the top of sprite spritenum
set totalheight=the height of member curcast
repeat while the mousedown
if the rightMouseDown then
set mult=5
else
set mult=1
end if
if delta>0 then
set pos=min(pos+delta*Mult,totalheight-textwidth)
else
set pos=max(pos+delta*mult,0)
end if
set the scrolltop of member curcast to pos
end repeat
set the membernum of sprite btnsprite to btn
updateStage
puppetsprite btnsprite,false
end
on resetAllText prefix
if voidP(prefix) then set prefix="d_"
repeat with index=1 to the number of members
if the type of member index=#richText then
set the scrolltop of member index to 0
end if
end repeat
end
on pressbtn
set spritenum=the clickon
set upcast=the membernum of sprite spritenum
set downcastname=the name of member (upcast)&"down"
set downcast=the number of member (downcastname)
puppetsprite spritenum,1
set the membernum of sprite spritenum to downcast
updatestage
repeat while the mousedown
end repeat
set the membernum of sprite spritenum to upcast
updateStage
puppetsprite spritenum,false
return rollover(spritenum)
end
on setpuppets startpuppet,endpuppet,state
repeat with spritenum=startpuppet to endpuppet
puppetsprite spritenum,state
end repeat
end
on getObj objname
set oldDelimiter=the itemDelimiter
set the itemDelimiter=quote
set foundobj=0
repeat with obj in the actorlist
if item 2 of string(obj)=objname then
set foundobj=obj
exit repeat
end if
end repeat
set the itemDelimiter=oldDelimiter
return foundobj
end
on makeDescr startcast,endcast,prefix
repeat with index=startcast to endcast
set text=the text of member index
set the name of member index to prefix&(line 1 of text)
end repeat
end
on getDrive
set drive=the moviepath
set oldDelimiter=the itemdelimiter
set the itemdelimiter=":"
set drive=(item 1 of drive)&":"
set the itemdelimiter=oldDelimiter
return drive
end
on numbercast startcast,endcast,startval
if voidP(startval) then set startval=1
repeat with curcast=startcast to endcast
set the name of member curcast to (the name of member curcast)&(startval+curcast-startcast)
end repeat
end
on setsoundpos castname,minpos,maxpos,orient
set spritenum=castsprite(castname)
puppetsprite spritenum,true
set pos=maxpos-(the soundlevel)*(maxpos-minpos)/7
if orient=#vert then
set the locV of sprite spritenum to pos
else
set the locH of sprite spritenum to pos
end if
updateStage
end
on setSoundval minpos,maxpos,orient
set spritenum=the clickon
set soundlist=["mute","barely audible","very quiet","quiet","moderate","medium loud","loud","loudest"]
puppetsprite spritenum,true
set upcast=(the membernum of sprite spritenum)
set basename=the name of member upcast
set downcast=the number of member (basename&"Down")
set the membernum of sprite spritenum to downcast
repeat while the mousedown
if orient=#vert then
set the locV of sprite spritenum to min(max(the mouseV,minpos),maxpos)
else
set the locH of sprite spritenum to min(max(the mouseH,minpos),maxpos)
end if
updateStage
if orient=#vert then
set the soundlevel=7-min(max(integer((the locV of sprite spritenum)-minpos)*8/(maxpos-minpos),0),7)
else
set the soundlevel=7-min(max(integer((the locH of sprite spritenum)-minpos)*8/(maxpos-minpos),0),7)
end if
global gStatus
setBtnText gStatus,basename&"Down","The volume is "&getat(soundlist,the soundlevel+1)
puppetsound "LED05.AIF"
end repeat
set the membernum of sprite spritenum to upcast
updateStage
end
on castsprite castname
set spritenum=0
repeat with index=1 to 48
if the membernum of sprite index>0 then
if the name of member (the membernum of sprite index)=castname then
set spritenum=index
exit repeat
end if
end if
end repeat
return spritenum
end
on resetpuppets
repeat with spritenum=1 to 48
if the castnum of sprite spritenum>0 then
if the puppet of sprite spritenum then
set the puppet of sprite spritenum to false
end if
end if
set the visible of sprite spritenum to true
end repeat
end