ruffle icon indicating copy to clipboard operation
ruffle copied to clipboard

`Avm1Function`'s `base_clip` field should be a string path, not a display object

Open Lord-McSweeney opened this issue 2 years ago • 1 comments

Describe the bug

In core/src/avm1/function.rs

pub struct Avm1Function<'gc> {
    ...
    base_clip: DisplayObject<'gc>, // <-- This should be a string path to the base clip
    ...
}

I haven't tested whether this is version-gated or not.

Expected behavior

The function references whatever DO is at the path instead of keeping a reference to a specific DO.

Content Location

Champion Archer (#6124) is broken due to this.

Affected platform

Desktop app

Operating system

Irrelevant

Browser

Irrelevant

Additional information

This is the root cause of #6124.

Lord-McSweeney avatar Dec 31 '23 05:12 Lord-McSweeney

Test for this: function_base_clip_readded.zip

Dinnerbone avatar May 19 '24 20:05 Dinnerbone