HTML5 vps update

HTML5 vps update

Postby socrates » May 12th, 2018, 8:11 am

https://github.com/haxball/haxball-issu ... dless-Host

Basro has released this update to allow for lightweight vps hosting where the game and sounds are not rendered. Anyone able to try? Hopefully its better for people having problems.

I guess this can even be used on regular hosts if the host isn't playing.

To use it go to https://html5.haxball.com/headless and open your browser console (right click and inspect element or F12 Developer tools).
Then on the console tab make sure your layer is the top level html5.haxball.com
Then you can enter commands as detailed by basro.
var room = HBInit({ roomName: "My room", maxPlayers: 16 }); will open a basic 16 man room called My Room.
  • 2

User avatar
socrates
 
Posts: 2460
News Articles: 69
Reputation: 223

Joined: August 24th, 2011, 11:00 pm


Re: HTML5 vps update

Postby socrates » May 12th, 2018, 10:01 am

When I host this way using just my regular host then cpu usage doesn't go above 1%.

Should be good for any cheaper vps which struggled to render the game.

Based on basro's instructions I'm also wondering if the following things are possible:
- set the game to automatically pause if someone types p in chat (even if they arent admin)
- add some voteban or votekick logic to the room

It would be good for hosting pubs as you could leave the room open permanently and it would automatically assign admins if players leave etc.
  • 0

User avatar
socrates
 
Posts: 2460
News Articles: 69
Reputation: 223

Joined: August 24th, 2011, 11:00 pm


Re: HTML5 vps update

Postby Yawn » May 12th, 2018, 3:38 pm

socrates wrote:When I host this way using just my regular host then cpu usage doesn't go above 1%.

Should be good for any cheaper vps which struggled to render the game.

Based on basro's instructions I'm also wondering if the following things are possible:
- set the game to automatically pause if someone types p in chat (even if they arent admin)
- add some voteban or votekick logic to the room

It would be good for hosting pubs as you could leave the room open permanently and it would automatically assign admins if players leave etc.


This would get abused, especially in public by trolls :/
  • 0

Yawn
 
Posts: 133
News Articles: 0
Reputation: 302

Joined: July 26th, 2015, 5:44 pm

Position: Forward

Re: HTML5 vps update

Postby socrates » May 12th, 2018, 3:53 pm

Yawn wrote:
socrates wrote:When I host this way using just my regular host then cpu usage doesn't go above 1%.

Should be good for any cheaper vps which struggled to render the game.

Based on basro's instructions I'm also wondering if the following things are possible:
- set the game to automatically pause if someone types p in chat (even if they arent admin)
- add some voteban or votekick logic to the room

It would be good for hosting pubs as you could leave the room open permanently and it would automatically assign admins if players leave etc.


This would get abused, especially in public by trolls :/


Well they wouldn't be admin ofc - so anyone doing this would be visible and could be banned.

Another nice thing savi did when testing earlier was a !switch command which would automatically swap all of red and blue team. (not when the game has started ofc).
  • 0

User avatar
socrates
 
Posts: 2460
News Articles: 69
Reputation: 223

Joined: August 24th, 2011, 11:00 pm


Re: HTML5 vps update

Postby lajz » May 12th, 2018, 5:46 pm

I tried that with friend on my vps. He was able to get a bot to write goal scorers on chat (e.g. Team RED scores- goal xy assist yz), getting an admin with "login" (generated token on his site). Sadly we did it on flash, right after HTML came out. We lost motivation to do it since everyone moved to new version of haxball.
  • 1

lajz
 
Posts: 16
News Articles: 0
Reputation: 103

Joined: March 4th, 2018, 6:54 pm


Re: HTML5 vps update

Postby Grep » January 2nd, 2019, 1:39 pm

I did this a $5 VPS [per month] and managed to create a bot which calculates successful passes, goals, assists, etc and determines who was man of the match!
  • 0

Image

People say 'go with the flow' but do you know what goes with the flow? Dead fish.
User avatar
Grep
 
Posts: 10
News Articles: 0
Reputation: -11

Joined: December 29th, 2018, 7:32 pm



Return to Announcements

Who is online

Users browsing this forum: No registered users and 2 guests