home *** CD-ROM | disk | FTP | other *** search
- property progressInc, progressSize, theFrame, initialRect
-
- on new me
- return me
- end
-
- on terminateProgress me
- set frame to theFrame
- tell window 1
- set the locH of sprite (26 + frame) to 9000
- updateStage()
- end tell
- end
-
- on initprogress me, frame, numberOfSteps
- set theFrame to frame
- set progressInc to 38.0 / numberOfSteps
- set progressSize to 0
- tell window 1
- set R to the rect of sprite (13 + frame) - [300, 0, 300, 0]
- end tell
- set initialRect to R
- tell window 1
- set the locH of sprite (13 + frame) to the locH of sprite (13 + frame) - 300
- end tell
- end
-
- on progress me
- set lastProgressSize to progressSize
- set progressSize to min(37, integer(progressSize + progressInc))
- if not (progressSize = lastProgressSize) then
- set frame to theFrame
- set newRect to initialRect + [0, progressSize, 0, 0]
- tell window 1
- set the rect of sprite 27 to newRect
- updateStage()
- end tell
- end if
- end
-