Closed tomjn closed 2 years ago
Brief mockup of the basic lobby UI frame:
AFL2 | [ ] tomjn |
---|---|
Singleplayer | Current screen gets displayed here |
+ New Game | |
DSD FFA | |
Red Comet 2v2 | |
Settings |
The unitsync problem has been a major thorn in my side, it was a huge time sink with AFLobby, and it's gotten worse since then.
For now to get things moving it'll be necessary to hardcode the game/map list.
However, I'd really like to:
If interfacing directly with unitsync in Node isn't possible, then I have some alternatives:
go
app that does the interfacing, and spits out the data as JSON, and minimaps in a folder
go
languageAs for native Node, N-API may provide the solution https://nodejs.org/api/n-api.html but I know little of how it works
For login, OAuth2 is the paradigm of choice, this means we can login users via other services such as Discord, or provide multiple options.
E.g.
By using OAuth2, we also eliminate the need to implement authentication from scratch at the client end, they can just use a generic library for their programming language. As a result, existing bots such as hubot or slackbots would be able to authenticate with minimal changes if any. Automation would be significantly easier
Basic UI frame up and running:
Using the codename necrontyr
, colours need adjusting, not a fan of the teals. Next step will be to integrate react router
Finally excised the blue header, added disabled menu items for campaign and replays
I like this!
A fortuitous consequence of using a custom post type in WP to represent battles, is that they can have comments if so desired. This might actually provide a crude means of battle chat complete with a historical record/backhistory
I fear you're adding extra baggage that turns this into SpringLobby 2.0 in many ways – just cut off the hands and the feet. I'd be really interested to see the rest of your plan to understand it so I can discuss with you more fully about things, but for now I'd pitch what I envision.
Let's start with a bit of background first, though.
What does a user currently have to do to play a game?
-1. Discover BAR Website
The SpringLobby Way: (worst case scenario. Most players won't spam the start button for example)
The Chobby Way: (not quite worst case scenario)
What should it take to get a new player ingame?
Click a link on an application deep link on the website which launches the lobby, puts them in the queue they selected, and as soon as practical the game starts. If a user wants to leave the queue they press a "Leave Queue" command.
If the user hasn't downloaded the lobby yet, it automatically downloads the lobby instead of just launching it. Or less ideally, on clicking the link a "Download lobby" button appears beside the link also, just in case they haven't downloaded it yet. On launching the lobby, if it's launched within 5 minutes (or so) of downloading it automatically adds them to the queue they selected (according to a config included in the app bundle when downloaded.) Else it presents them with a similar list to what they see on the website.
Lobby should download with the latest game + engine version, plus all maps in the standard queue, so a user never sees downloading, except when they first get the game, or when an update is pushed. Ideally.
Although. If they're downloading from the main page, should just download the map in the queue that the player selected to speed up download times? Then the lobby will download the missing content in the background.
Login details are saved in keychain, or similar programs, for users who have already logged in. An option to log out/switch account would be important. For new players, logging in should be as simple as typing in their wanted username, and it's assigned to them as soon as they claim it. If it's already taken, ask them to choose a new one (or show a password field so they can log in?) Passwords could be automatically generated and stored securely in a password manager. An option to retrieve the password so they can log in on another machine is important.
If a player isn't being redirected from the website, they should have access to a
Features players will probably want
My Concerns With My Own Proposal
This post will be revised to add things as I remember what I wanted to put here, or as suggestions & criticisms are made.
I don't intend to add a lot of what you've mentioned:
There isn't any.
There won't be channels in this lobby, at least not in v1, I question if they're needed at all. If they're ever added, they'll be de-emphasised. They certainly aren't going to be built first like most lobbys. Tbh if I were to organise a game with friends, I'd probably fire up a zoom room so we can talk and ignore the lobby channels completely.
The only chat I see happening in the next few months is battle chat, but that doesn't mean someone couldn't build a chat component and add it to the sidebar. Eitherway chat is not the primary purpose of a game lobby, gaming is, and most games don't have it.
Login details are saved in keychain, or similar programs, for users who have already logged in. An option to log out/switch account would be important.
User switching isn't in minimum viable lobby, perhaps several months down the line. But with no clans, and no rankings, I see minimal utility in the feature. In the future it would have more relevance.
As for email, the lobby itself doesn't need email verification, or emails at all. That's up to whatever OAuth2 provider gets used. It would seem that most of the OAuth2 part is already built on the server side by other people already. I don't consider this a part of the lobby project, but instead its own parallel thing. A login/register button takes you to the browser.
However:
Lobby should download with the latest game + engine version, plus all maps in the standard queue, so a user never sees downloading, except when they first get the game, or when an update is pushed. Ideally.
The most I expect is an indicator next to a player to say they're downloading things, and a progress bar in the top to show your progress. It should be contextual, I don't like the idea of having a dedicated download page, and if I did add one it would be for acquiring new content, more like a map store.
But I don't consider this within the scope of minimum viable lobby
If the user hasn't downloaded the lobby yet, it automatically downloads the lobby instead of just launching it.
I really don't like downloading a downloader. The initial download should be able to get you ingame with singleplayer. I also don't intend to have this UI shown inside the browser on the website. If it's running in a browser, it's because you have the browser and react dev tools and webpack watch running to debug something. This is a desktop app.
But what about LAN Parties, when all this falls apart? Is it safe to assume that since this is an open source community, people will indefinitely be able to rely on our servers? I don't think we should assume this.
Technically a server is just any WP site with a specific plugin installed. A multisite would thus be able to host hundreds of servers from a single installation. You can install WP with a 1 click installer on most cheap hosts. As for the plugin itself, it just needs to define some data types, which is stupidly easy. I went to WP Generator and filled out some questions and it populated an array of options I copy pasted into a local dev environment.
Given this would use Node, and the REST API is rather simple, a future experiment might be to use one of the Node CMS' and spin up a mini web server in the background that just uses these API points then advertises it locally or gives instructions to other people.
As for authenticating private battles, and private LANs, I'd like to rip off Pokemon Go. Don't show the battles at all, just add an option to enter a private battle, and give it a code, e.g. pidgey squirtle alakazam. It could be customized instead to BAR units or memes like nyan cat. This way private battles are truly private, and don't clog up the battle list.
But while I have these in mind, these are not minimum viable lobby, so are not currently in scope.
Singleplayer:
Multiplayer:
If a user already has BAR and an identity then:
Right now I've several competing thoughts about the exact layout of the battle screen, but I've plenty to do before I reach that point. However, I don't want a great big panel of options and settings. I'd like to eliminate as many as possible or move them to a new host screen.
Part of me wanted to make it so that battle rooms have a map, and you'd need to open a new room with a new map, but that just sounds really annoying so I killed that.
Some brief progress updates
Neutralino on MacOS doesn't work, it may work fine for Windows/Linux but this oversight is not a good sign for the project. On first glance, someone popped up and added MacOS support then left. I don't believe the maintainer has the ability to test Mac support, or even understands how apps on MacOS work ( they suggested doubleclicking to launch a raw compiled binary that wasn't in a .app
bundle )
Just for personal reference, some battle room research I had in tabs
I quite like the PA layout, though I would reorder and redesign a lot of that sidebar. I thought I'd taken screenshots of Stellaris and some others but misplaced them, Stellaris has a 3 column layout, players/chat/options with a start button at the bottom
Notalobby SP
- I'd prefer it if the lobby came with an engine and the game, and at least 2 or 3 maps. Alternative engines is more for testing and replays. Unless these differ from the current status quo I see no need to mention them in the UI. There is the current BAR and then there are other versions of BAR
I fear that by relying on Uberserver, you greatly increase the difficultly of maintaining this paradigm, and not being sucked back into the current lobby paradigm of Chobby, or worse, even SpringLobby.
But to each their own; I shall cease to bother you now.
Although I'll take a moment to clarify something:
My idea was to not download a downloader: The website isn't a lobby on the player's computer; instead, a new player finds the website "oh that's cool", sees a button to play and presses it, and he instantly receives a download of everything he needs. (Afaik a purely in-website lobby is not possible, but if possible that would likely be ideal.) All he has to do then is open the lobby and he's put in a queue, ready to play.
In the background, invisible to the user, the lobby then collects all assets that weren't needed for that first game, as soon as possible (?). Everything needed to join the queue and get ingame in the first place was already downloaded within the lobby package itself, again invisible to the user.
I fear that by relying on Uberserver, you greatly increase the difficultly of maintaining this paradigm, and not being sucked back into the current lobby paradigm of Chobby, or worse, even SpringLobby.
I have no intention of supporting uberserver in any way shape or form. Uberserver and the TASServer protocol will burn with the fire of a thousand suns. For my official stance at length on the subject, please refer to this helpful video
My idea was to not download a downloader: The website isn't a lobby on the player's computer; instead, a new player finds the website "oh that's cool", sees a button to play and presses it, and he instantly receives a download of everything he needs. (Afaik a purely in-website lobby is not possible, but if possible that would likely be ideal.) All he has to do then is open the lobby and he's put in a queue, ready to play.
Women play RTS games too, but what you're describing just sounds like a download link.
In the background, invisible to the user, the lobby then collects all assets that weren't needed for that first game, as soon as possible (?). Everything needed to join the queue and get ingame in the first place was already downloaded within the lobby package itself, again invisible to the user.
My preference is an installer that installs the game, old school style. None of this collecting assets and downloading assets nonsense. If you want extra maps or updates that's a different thing. Installing the base game should install the base game, that the lobby is built with JS and HTML should have no effect on the website at all, it's just an implementation detail, like which type of screws and nails were used in building your house
I'm all for oldschool / basic style. Lean and mean.
When joining a server, things should auto-download however. That is a huge benefit. Preferably also as fast as possible AND ideally showing progress to other players how much % is downloaded/installed.
For hosting your own game or play single/offline, there should be an easy way to get new maps, or widgets or other 'mods'. This need to be some sort of a 'subscribed' list (could be a bit like steam workshop). Ideally, this would be linked to your account, so if you re-install and re-login the lobby knows what maps/stuff to download.
Most important thing is that the lobby is fast, intuitive and also very(!) easy to setup games. Choose a game-type-mode, choose starting locations, setup the teams, do balancing stuff, add scavengers or random-drops or whatever modoption. This is currently costing way too much time and also fun.
quick update on battleroom scaffolding:
Also some Starcraft screenshots:
Just putting this here:
Also, I like that Starcraft 2 has a separate singleplayer UI that streamlines things, I got a friend to send newer screenshots:
The broad stroaks:
POST
requests/wp-json/lobby/v1/bar/1234
and start an instance, thenPOST
to that endpoint to say you've started, let us know at the end who won/lost.npx
, e.g.npx spring-start --engine=".." --map=".." --game="..."
etc should download the relevant engine if it's not already, then start up a headless spring. Anybody with node could spin it up with easespring-launcher
was hived off into its own package so that mutual maintenance could happen. I don't fancy rebuilding basic stuff like this from scratch, better to share and improve alike. There should be a lot of small utility packages at the end of this, nice building blocks everybody can use, be they javascript or typescriptjest
for testing, in particular snapshotsfetch
polyfill for API requestsI've identified these projects will be needed: