Temple of The Roguelike Forums

Development => Programming => Topic started by: miki151 on September 30, 2013, 05:49:49 PM

Title: Asm.js, C/C++ in the browser
Post by: miki151 on September 30, 2013, 05:49:49 PM
I think it's a pretty neat technology. It's basically a C/C++ to javascript compiler. So in theory you can port any C/C++ program to the browser. Supposedly the newest Firefox can run this code really fast, without much performance loss.
http://www.extremetech.com/gaming/154994-epic-mozilla-release-unreal-engine-3-html5-demo-to-the-public-and-its-awesome

It means that maybe we will soon be playing the old classics in the browser, on any device. Save files and high score automatically uploaded to a server.

I gave it a try, it's pretty straightforward. SDL is available in the toolchain, so best to use that.
Title: Re: Asm.js, C/C++ in the browser
Post by: guest509 on October 01, 2013, 11:11:46 AM
yay
Title: Re: Asm.js, C/C++ in the browser
Post by: TheCreator on October 01, 2013, 11:30:04 AM
So in theory you can port any C/C++ program to the browser.

I'd love to see my shitty code ruining the theory :).
Title: Re: Asm.js, C/C++ in the browser
Post by: Krice on October 01, 2013, 12:46:31 PM
I don't get what is the idea to run a game in browser. I never play browser games.
Title: Re: Asm.js, C/C++ in the browser
Post by: wire_hall_medic on October 01, 2013, 06:02:06 PM
I don't get what is the idea to run a game in browser. I never play browser games.

I rarely do either.  However, there have been quite a few games I haven't played because I wasn't willing to download them.