2 ms·
Not often I find a C project that can compile to JS via emscripten without too much work. http://i.imgur.com/XMZE04i.png http://i.imgur.com/XMZE04i.png If it
by ac2u 12y ago
Not often I find a C project that can compile to JS via emscripten without too much work.
http://i.imgur.com/XMZE04i.png http://i.imgur.com/XMZE04i.png
If it takes off for game engines then it could be used for scripting canvas/webgl games too.
- munificent 12y agoNeat! I'd wondered about that but didn't have the time to try.
- ac2u 12y agoIt more or less worked out of the box with latest emscripten, the only thing I replaced was the call to getline with an inline version pulled from google code. More work needed to make the REPL more user friendly in HTML (emscripten uses browser prompts to get input when you follow basic instructions to output to HTML but could tweak to have a more user-friendly REPL experience). Additionally you can do things like the what has been done with the emscripten port of Lua and supply wren with a bridge interface to work with the DOM directly. From that it's a short path to having <script language="text/wren"> with a bootstrap script to parse them out and feed to the wren engine :-) Of course if it were as easy as typing this out i'd be doing it already!