home *** CD-ROM | disk | FTP | other *** search
- on exitFrame
- global keyHotspots, castData, n, x1, y1, hiliteFlag
- set x to the mouseH
- set y to the mouseV
- set n to PCinRect(x, y, keyHotspots)
- if n <> EMPTY then
- if (n = 10) and (marker(0) = 1) then
- go(the frame - 1)
- exit
- end if
- if (n = 11) and (marker(0) = marker(line the number of lines in the labelList - 1 of the labelList)) then
- go(the frame - 1)
- exit
- end if
- set l to line n of keyHotspots
- set x1 to value(item 1 of l)
- set y1 to value(item 2 of l)
- set x2 to value(item 3 of l)
- set y2 to value(item 4 of l)
- set castData to item 6 to the number of items in l of l
- set the castNum of sprite 5 to the number of cast (item 1 of castData && "hilite")
- spriteBox(5, x1, y1, x2, y2)
- set the visible of sprite 5 to 1
- go(the frame - 1)
- else
- set the visible of sprite 5 to 0
- end if
- if rollOver(6) and (item 3 of castData = "showPopMenu") then
- manageRollOverMenu()
- else
- if rollOver(39) and (item 1 of castData <> "searchResults") then
- if the castNum of sprite 38 <> the number of cast "index" then
- setUpTextHilite(39)
- end if
- go(the frame)
- exit
- end if
- end if
- if hiliteFlag = 1 then
- set the visible of sprite 48 to 0
- set hiliteFlag to 0
- end if
- go(the frame)
- end
-
- on setUpTextHilite theSpriteNum
- global hiliteFlag, linePtr, displayLines
- puppetSprite(48, 1)
- set the castNum of sprite 48 to 414
- set x to the castNum of sprite theSpriteNum
- set LT to the left of sprite theSpriteNum
- set TP to the top of sprite theSpriteNum
- set wd to the width of sprite theSpriteNum
- set txtHt to the textHeight of field x
- set the visible of sprite 48 to 0
- set the locH of sprite 48 to LT
- set the width of sprite 48 to wd
- set the height of sprite 48 to txtHt + 1
- set vPos to the mouseV
- set linePtr to integer((vPos - TP) / txtHt)
- if (linePtr + 1) > displayLines then
- set the visible of sprite 48 to 0
- exit
- end if
- set the locV of sprite 48 to integer(TP + (linePtr * txtHt))
- set the visible of sprite 48 to 1
- set hiliteFlag to 1
- end
-
- on manageRollOverMenu
- global castData, rectList
- set baseCastNum to value(item 4 of castData)
- set mItems to value(item 5 of castData)
- set LT to value(getAt(rectList, 1))
- set TP to value(getAt(rectList, 2))
- set rt to LT + value(getAt(rectList, 3))
- set bt to TP + value(getAt(rectList, 4))
- set castPtr to 0
- set x to the mouseH
- set y to the mouseV
- if (x >= LT) and (x <= rt) then
- if (y >= TP) and (y <= bt) then
- set castPtr to integer(0.5 + ((y - TP) * mItems * 1.0 / (bt - TP)))
- set the castNum of sprite 6 to baseCastNum + castPtr
- else
- set castPtr to 0
- set the castNum of sprite 6 to baseCastNum
- end if
- else
- set castPtr to 0
- set the castNum of sprite 6 to baseCastNum
- end if
- updateStage()
- end
-