|
|
|
SM scroll control
Added on 4/15/2000
|
Part 2/3 of the Scrolling menu set.
You must use this in conjunction with the "SPRITE SCROLL" behavior.
Attach this behavior to one or more sprites to serve as a button to control the movement of the scrolling sprites
Actions are called on mouseenter and moueleave. You can change them to something else, if you wish.
Download PC Source Download Mac Source
--Scroll Control part 2/3 of the Scroll Menu set.
--Created by Brent Moseley April 2000
--brent099@xoommail.com
property enteraccel
property exitaccel
property entermax
property exitmax
on mouseenter me
sendallsprites(#setmoveinc , enteraccel , entermax)
end
on mouseleave me
sendallsprites(#setmoveinc , exitaccel , exitmax)
end
on getPropertyDescriptionList
set description = [:]
addProp description, #enteraccel, [#default: .5, #format:#float, ¬
#comment:"Acceleration on mouseenter", #range: [#min:-2, #max:2]]
addProp description, #exitaccel, [#default: .5, #format:#float, ¬
#comment:"Deceleration on mouseexit", #range: [#min:-2, #max:2]]
addProp description, #entermax, [#default: 3, #format:#integer, ¬
#comment:"Max speed on mouseenter", #range: [#min:-10, #max:10]]
addProp description, #exitmax, [#default: 3, #format:#integer, ¬
#comment:"Max speed on mouseexit", #range: [#min:-10, #max:10]]
return description
end
on getBehaviorDescription
return "Use in conjunction with the "SPRITE SCROLL" behavior." & RETURN & RETURN & ¬
"Attach this behavior to one or more sprites to serve as a button to control the movement of the scrolling sprites" ¬
& RETURN & RETURN & "Actions are called on mouseenter and moueleave. You can change them to something else, if you wish."
end
|
|