home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
CD-ROM Today (BR) Volume 2 #9
/
CDRTV2N9.iso
/
progs
/
vearth
/
shared.dir
/
00547_Script_547
< prev
next >
Wrap
Text File
|
1996-04-15
|
5KB
|
202 lines
on cleanChannels Begin, End
repeat with var = Begin to End
puppetSprite var, FALSE
end repeat
end cleanChannels
on putBar num
repeat with var = 5 to 33
puppetSprite var, TRUE
if (var >= (22 + num)) then
set the visible of sprite (var) to FALSE
end if
end repeat
updateStage
end putBar
on switchOn num
global gPage
putOn(the clickOn-21)
updateStage
end
on putOn num
global gPage, gMaxPage
repeat with myVar = 0 to gMaxPage -1
set the castNum of sprite (22 + myVar ) to (513 + myVar * 2 ) --OFF
end repeat
set the castNum of sprite (22 + num -1 ) to (513 + (num-1) * 2 + 1) --ON
updateStage
set gPage = num
end
on setBookmark
global gChapter, gSection, gPage, gCorrect
global gBookPage, gBookFrame, gBookCorrect
global gBookMovie
go loop
set gBookFrame = the frame
set gBookMovie = the movie
set gBookCorrect = gCorrect
set gBookPage = gPage
end
on findBookmark
global gBookFrame, gBookMovie, gBookPage, gBookCorrect
global gPage, gChapter, gCorrect
if gBookMovie = EMPTY then exit
cleanChannels(5,48)
if gBookMovie = the movie then
go frame gBookFrame
else
go frame gBookFrame of movie gBookMovie
end if
set gPage = gBookPage
set gCorrect = gBookCorrect
if gPage > 0 and gChapter > 4 and gChapter < 11 then putOn(gPage)
end
on setBookmark2
global gChapter, gSection, gPage, gCorrect
global gBookPage, gBookFrame, gBookCorrect
global gBookMovie
go loop
set gBookFrame = the frame
set gBookMovie = the movie
set gBookCorrect = gCorrect
set gBookPage = gPage
end
on findBookmark2
global gBookFrame, gBookMovie, gBookPage, gBookCorrect
global gPage, gChapter, gCorrect
if gBookMovie = EMPTY then exit
cleanChannels(5,48)
if gBookMovie = the movie then
go frame (gBookFrame)
else
go frame (gBookFrame) of movie gBookMovie
end if
set gPage = gBookPage
set gCorrect = gBookCorrect
if gPage > 0 and gChapter > 4 and gChapter < 11 then putOn(gPage)
end
on getWhere myString
global gPage
-- set the blend of sprite (the clickOn) to 30
updateStage
if myString = EMPTY then exit
set myMovie = getFirst(myString)
set head = (the number of chars in myMovie) + 2
set myString = chars(myString, head , the number of chars in myString)
set section = getFirst(myString)
set head = (the number of chars in section) + 2
set myString = chars(myString, head , the number of chars in myString)
set page = getFirst(myString)
set head = (the number of chars in page) + 2
set myString = chars(myString, head , the number of chars in myString)
if myString = EMPTY then
set myMarker = myMovie & "." & section & "." & page
else
set myMarker = myMovie & "." & section & "." & page & "t"
end if
go frame myMarker of movie (myMovie & "-" & section & "")
set gPage = value(page) -- page is string
if gPage > 0 then putOn(gPage)
-- put gPage
-- put myMarker
end
on getFirst myString
if char 2 of myString = "." or char 2 of myString = EMPTY then
return chars(myString, 1, 1)
end if
if char 3 of myString = "." or char 3 of myString = EMPTY then
return chars(myString, 1, 2)
end if
end
on playEye mySound
-- Eyewitness
global gSound
if gSound = 0 then
set gSound = 1
sound stop 1
set the blend of sprite (the clickOn) to 70
-- set the soundEnabled to TRUE
-- preLoadCast the number of cast mySound
puppetSound mySound
set the soundEnabled to TRUE
updateStage
starttimer
repeat while the timer < 100
nothing
end repeat
repeat while soundBusy(1)
if the mousedown then
exit repeat
end if
end repeat
sound stop 1
puppetSound 0
set the soundEnabled to false
-- set gSound = 1
if the type of sprite 4 = 16 then
set the sound of cast the castNum of sprite 4 to 1
set the volume of sprite 4 to 200
end if
else
set gSound = 0
sound stop 1
set the soundEnabled to FALSE
puppetSound 0
set the blend of sprite (the clickOn) to 100
updateStage
if the type of sprite 4 = 16 then
set the sound of cast the castNum of sprite 4 to 1
set the volume of sprite 4 to 200
end if
end if
end