Nice, we got Hungary Heros in 2012 to cross compile with the Randori compiler.
Some of the issues you stated I had to correct for in that compiler but never made it into FalconJX's emitter. Curious, what are your plans for this? Are you attempting to have a fork of Starling run n WebGL? Basically, I am really interested in what your goals are because if you are saying this is more then a prototype, I might be willing to give some code work in the next month/2 if you can nail down bugs and features that need to be fixed/implemented. I know the compiler a little bit anyway. :) Mike On Tue, Apr 5, 2016 at 4:44 PM, Nimai <[email protected]> wrote: > We (actually, my coworker Bill) got the entire Starling 2.0 framework > successfully transpiled to JavaScript using FalconJX! > > We are using lizhi's spriteflexjs library to provide code for the flash > runtime APIs. > > In order to get a successful compilation, we developed a way to emit the > goog requires and depends in a way that is correct for ActionScript3 import > and extends, avoiding circular dependencies. > > At a high level, here's how the code organization changed: > * Static class var initialization is run later, not when the js file is > loaded. > * All requires (other than extend/inherit classes) moved to the > project-dependencies.js file. > > A handful of ActionScript code workarounds were required in the Starling > 2.0 > codebase, which we hope to turn into FalconJX unit tests, and pursue fixes. > Hacks to the Starling 2.0 code include: > * internal class vars were changed to public. > * Local functions (functions inside of functions) needed to be assigned to > and accessed through a var. > * Inline XML (in the Starling demo class) commented out for now. > * One place using "apply" did not emit properly formed JavaScript code; > worked around for now. > * The namespace "starling.core.starling_internal" was showing up in > requires > but is not a module. > * The @flexjsignorecoercion was used to ignore casts to Class. > * Other uses of Class commented out for now, such as "if (foo is Class)..." > * Vars inside of class methods were confused by class accessors (getters) > of > the same name. > > > Where are we now? We have JavaScript code that loads and runs in the > browser, but it doesn't get very far. There are more Flash APIs that need > filling out in the spriteflexjs library. We will enumerate what we've > found > so far. > > We are working on a patch or pull request with the FalconJX compiler code > changes related to the use of goog requires and depends. > > > > > -- > View this message in context: > http://apache-flex-development.2333347.n4.nabble.com/Starling-framework-compiled-to-JavaScript-tp52188.html > Sent from the Apache Flex Development mailing list archive at Nabble.com. >
