ruffle-rs / ruffle

A Flash Player emulator written in Rust
https://ruffle.rs
Other
15.72k stars 816 forks source link

Support magic button frame labels in movie clips #4261

Closed Herschel closed 4 months ago

Herschel commented 3 years ago

In a MovieClip, you can place magic frame labels of _up, _over and _down. If the clip is in "button mode", it will automatically toggle between these frames as the mouse hovers, like a standard Button/SimpleButton.

This can be done in both AVM1 and AVM2. In AVM1, "button mode" is triggered by attaching any button event handler to the clip, such as on(release). In AVM2, there is an explicit Sprite.buttonMode property that can be set to true.

Sample SWFs: button-clip.zip

midgleyc commented 3 years ago

I think this causes #3821.

depPat commented 3 years ago

Hi ! i'had a look on your button clip.... and things seem missing : script is'nt full.... Go and see this (as2 only.... I don't like/use as3 !) buttonClip-fix.zip

Lord-McSweeney commented 4 months ago

This is working now on both avm1 and avm2.