Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Write dense elements in ECMAArray with amf0 #55

Merged
merged 2 commits into from
Feb 18, 2024

Conversation

evilpie
Copy link
Contributor

@evilpie evilpie commented Feb 17, 2024

Fixes #54

@Dinnerbone
Copy link
Contributor

Can you find/make a test for this please, in this repo?

@evilpie
Copy link
Contributor Author

evilpie commented Feb 18, 2024

I generate this test by running the following ActionScript code and copying the resulting .sol file:

var myStringArray = [];
myStringArray.one = "eins"
myStringArray.two = "zwei"

var emptyArray = [];

var holeyArray = [];
holeyArray.length = 15;

var holeyArray2 = [];
holeyArray2[1] = "one";

var denseArray = ["first", "second"];

var mixedArray = ["first", "second"];
mixedArray.propertyA = "aaaa";

SharedObject.defaultObjectEncoding = ObjectEncoding.AMF0;
var my_so: SharedObject = SharedObject.getLocal("AS2-ECMAArray-Demo");

my_so.data.myStringArray = myStringArray;
my_so.data.emptyArray = emptyArray;
my_so.data.holeyArray = holeyArray;
my_so.data.holeyArray2 = holeyArray2;
my_so.data.denseArray = denseArray;
my_so.data.mixedArray = mixedArray;

Copy link
Contributor

@Dinnerbone Dinnerbone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

❤️ Thanks!

@Dinnerbone Dinnerbone merged commit 2f77055 into ruffle-rs:master Feb 18, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AMF0 doesn't write dense elements in ECMAArray
2 participants