Idea: run JavaScript version of freeciv in 0AD?

Idea: run JavaScript version of freeciv in 0AD?

Postby Julius » 14 Mar 2015, 01:13

Maybe a crazy idea, but since all attempts to create a 3d rendering engine for freeciv have failed so far it could be feasible to run freeciv inside of 0AD?
There exists a HTML5/ JavaScript version of freeciv for running it in a web browser and 0AD has a full spidermonkey JavaScript implementation to run its AI and other scripts. Thus potentially a lot of work could be saved by combining the two?

Thoughts?
“Reality is that which, when you stop believing in it, doesn’t go away.” - Philip K. Dick
User avatar
Julius
Community Moderator
 
Posts: 3032
Joined: 06 Dec 2009, 14:02

Re: Idea: run JavaScript version of freeciv in 0AD?

Postby Sauer2 » 14 Mar 2015, 01:32

Not feasible, as far as I can see it at a glance.

The APIs exposed to the JavaScript interpreter are completely different.

In 0AD it's a very high-level, custom, non-browser API to facilitate bots and change game behavior.
In a web browser it's the classical dom + canvas + other basic stuff APIs acting as SDL replacement et al. and the freeciv port is probably done compiling the complete code base using Emscripten.
User avatar
Sauer2
 
Posts: 430
Joined: 19 Jan 2010, 14:02

Re: Idea: run JavaScript version of freeciv in 0AD?

Postby Julius » 14 Mar 2015, 01:41

Ahh OK, too bad then. Would have been cool ;)
“Reality is that which, when you stop believing in it, doesn’t go away.” - Philip K. Dick
User avatar
Julius
Community Moderator
 
Posts: 3032
Joined: 06 Dec 2009, 14:02

Who is online

Users browsing this forum: No registered users and 1 guest