Wesnothweb just like FreeCivweb

Brainstorm ideas of possible additions to the game. Read this before posting!

Moderator: Forum Moderators

Forum rules
Before posting a new idea, you must read the following:
Post Reply
User avatar
max_torch
Inactive Developer
Posts: 414
Joined: July 31st, 2011, 5:54 pm

Wesnothweb just like FreeCivweb

Post by max_torch »

Here's an idea that is sort of somewhere between practical and far-fetched: Make a browser-based version of Wesnoth, similar to https://www.freecivweb.org/.

The freecivweb game, even though its in a browser has:
  • Music and sound
  • Pretty good graphics
  • Responsive interface
  • Game and Display Settings
  • Full screen mode, when enabled looks more like a full game than a browser
One clear benefit is to have no more UI wonkiness because of CSS flexbox and grid responsive web design goodness. Another is no need to make code run for different operating systems, instead only for different browsers. Maybe all UMC would be integrated with this web version and thus be available and ready to load up, no more download and install, just select what you want enabled for your game. You can easily play Wesnoth on all devices- the catch is you need to have internet access, which, yes, is not yet spread to every single person throughout the world, or not spread in places of turmoil.

The Stack of FreeCivweb:
Stack.jpg
Stack.jpg (26.8 KiB) Viewed 1001 times
Wesnoth stack is practically a subset of their stack. Only thing I never heard of in their Stack is "Tomcat".
Anyone wanna weigh in on pros and cons? If ever this was done would we follow their stack?
User avatar
Pentarctagon
Project Manager
Posts: 5528
Joined: March 22nd, 2009, 10:50 pm
Location: Earth (occasionally)

Re: Wesnothweb just like FreeCivweb

Post by Pentarctagon »

Tomcat would refer to https://en.wikipedia.org/wiki/Apache_Tomcat

As for the actual idea, there was an attempt at this sort of thing previously (https://forums.wesnoth.org/viewtopic.php?t=43313), but it wasn't completed. Also worth noting is that just having the same stack doesn't necessarily mean a whole lot since even just "C and C++" is an immensely broad category.
99 little bugs in the code, 99 little bugs
take one down, patch it around
-2,147,483,648 little bugs in the code
User avatar
egallager
Posts: 576
Joined: November 19th, 2020, 7:27 pm
Location: Concord, New Hampshire
Contact:

Re: Wesnothweb just like FreeCivweb

Post by egallager »

There's been an attempt to get SuperTux to compile for web via Emscripten, and since SuperTux shares many of the same dependencies as Wesnoth does, the progress on that might make a new attempt at doing Wesnoth be more successful this time around.
gnombat
Posts: 682
Joined: June 10th, 2010, 8:49 pm

Re: Wesnothweb just like FreeCivweb

Post by gnombat »

There was also this but it only got as far as drawing the map (without any transitions). The live demo still works in Firefox but it seems to have issues with the current version of Chrome.
User avatar
max_torch
Inactive Developer
Posts: 414
Joined: July 31st, 2011, 5:54 pm

Re: Wesnothweb just like FreeCivweb

Post by max_torch »

Hmm, after seeing those WIP attempts, and the way web technologies and software advancements have been going, it almost seems like this finally being accomplished by someone someday for wesnoth seems like a when rather than an if. It's exciting. Fascinating to see that the way aidanhs is doing it is to completely parse and rebuild all wesnoth code, including UI bits, for rendering onto a browser. For doing something like this I was imagining more that UI would be rewritten in HTML/CSS/Java/Sass/etcetera, and other features and data handling also rewritten using Node.js or any other backend stuff, and only the game map rendering and game logic and AI code would be parsed/rebuilt.
shevegen
Posts: 497
Joined: June 3rd, 2004, 4:35 pm

Re: Wesnothweb just like FreeCivweb

Post by shevegen »

I think there were discussions for better www-support in the long run in the past (not only by me but several folks before). I also keep on advertising the "let everyone edit scenarios on-line if possible", e. g. collaborative editing possible (for those scenarios that enable it; of course I don't mean that EVERYONE should be designing a scenario but as a possibility this would be super-great. Imagine older folks being able to teach younger folks how to do that. You can probably work around via IRC, discord and whatever, but having this built-in and available would make a huge difference IMO. But I digress.)

> One clear benefit is to have no more UI wonkiness because of CSS flexbox and grid responsive web design goodness.

Don't get me wrong, I like the "modern" web. But you can not select only advantages and ignore disadvantages. Speed-wise I am 100% certain that right now there will be a definitive impact. Perhaps web-assembly can resolve this, but just look at things like electron - it's SLOW. C and C++ can be critisized for a lot of things, but speed-wise they are efficient.

Anyway - I think it is just a matter of time. Keep up the good and consistent game design, improve documentation and what not - I am sure eventually it may become a possibility one way or another. It's just a matter of time IMO.

Edit: In regards to collaborative editing, I also mean this a bit more like a wiki in progress. Not for every campaign, mind you, because some devs prefer better control. But free-collab campaigns where you don't have to load up wesnoth but instead just modify stuff/content on the www. After all WML is XML yes? And lua is text too so ... this should be possible. Perhaps even a wesnoth-IDE optimised for creating scenarios/campaigns! :D

Edit2: max_torch wrote: "it almost seems like this finally being accomplished by someone someday for wesnoth seems like a when rather than an if."
I didn't catch it in my original reply but I agree! I think it's a question of when rather than if. By the way as for stack-support, GTK also has gobject-introspection and ruby and python bindings due to gobject-introspection. Or the libui library - there are bindings for many languages too. C++ and especially C are really the programming languages where you can easily have tons of language bindings (even without SWIG; libui just uses ruby fiddle "internal" gem. I get funny crashes when I use it incorrectly, but when I use it correctly it works, using GTK on linux so it's just syntactic sugar really)
Post Reply