Home World Forum
Stars! AutoHost web forums

Jump to Stars! AutoHost


 
 
Home » Stars! 2.6/7 » The Bar » Stars! Browser Edition
Stars! Browser Edition Fri, 17 March 2017 22:44 Go to next message
raptor is currently offline raptor

 
Petty Officer 2nd Class

Messages: 53
Registered: June 2014
Hi,

Stars! can now be run in a web-browser. Grab the source code here and launch 'stars.html' in your web browser:

Download: https://github.com/stars-4x/stars-browser/archive/master.zip (~8 MB)

Main project page: https://github.com/stars-4x/stars-browser

A special thanks to John Vilk (author of BrowserFS) for fixing a very obscure bug to allow this setup to work.

Note: This is not set-up on a website, it is run from a local folder on your computer. If someone wants to host it and pull in the newest changes from time-to-time, then you could access it from a website.

I will accept pull requests for anyone who wants to add enhancements.

Try it out!

Report message to a moderator

Re: Stars! Browser Edition Fri, 17 March 2017 22:50 Go to previous messageGo to next message
raptor is currently offline raptor

 
Petty Officer 2nd Class

Messages: 53
Registered: June 2014
A note on enhancements:

Since everything can be done with JavaScript, you can use the Emularity and/or BrowserFS APIs to access files from the in-browser filesystem that Stars! uses. All that's needed is to edit the stars.html file and add your features... and give them back to the project mentioned in the opening post Smile

This could lead to the following possible enhancements:

    * Uploading a local file into the in-browser file system
    * Downloading a file from the in-browser file system
    * Pull a turn file from some location on the web into the file system.
    * Automatic turn file transfer from Autohost into your browser game


It will be a little while before I can work more on this, so help is welcome!

Report message to a moderator

Re: Stars! Browser Edition Sun, 19 March 2017 01:00 Go to previous messageGo to next message
Ron is currently offline Ron

 
Commander
Forum Administrator
Stars! AutoHost Administrator

Messages: 1181
Registered: October 2002
Location: Collegedale, TN
This sounds great! I won't have a chance to check this out for awhile, but am wondering how it handles putting in their serial numbers. I'm guessing the file system has to be persistent and players would only have to enter their serial code once, etc.

Wonder if it would work on an Android this way...



Ron Miller
Stars! AutoHost

Report message to a moderator

Re: Stars! Browser Edition Sun, 19 March 2017 01:18 Go to previous message
raptor is currently offline raptor

 
Petty Officer 2nd Class

Messages: 53
Registered: June 2014
Yes, the in-browser filesystem is persistant (it uses an IndexedDB) and will store the serial number after entering it the first time. This includes game files as well.

I provided a button on the page for you to wipe the filesystem because even clearing the browser cache does not seem to do it on Firefox.

It should work on any platform with a moderately modern browser.

Report message to a moderator

Previous Topic: Least useful component
Next Topic: Stars autohost client
Goto Forum:
  


Current Time: Sat Jul 22 22:51:22 EDT 2017