Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tournament lobby + dashboard #904

Merged
merged 22 commits into from
Oct 28, 2023
Merged

Conversation

sgfost
Copy link
Contributor

@sgfost sgfost commented Oct 18, 2023

add tournament lobby, dashboard
add banner to the landing page
add tournament participation links to the navbar, landing page, and footer

@sgfost sgfost added this to the Mars Madness Tournament 2023 milestone Oct 18, 2023
for code re-use with forthcoming tournament and education lobbies
need to implement TournamentLobby view which will basically be a
LobbyRoom component adapted to remove controls and to interface with the
tournament lobby room on the server
add freeplay/tourn lobby toggles and offsets to admin settings interface
- start to add tournament dashboard (pre-lobby) step
- refactor survey/tournament routes
alee and others added 8 commits October 25, 2023 18:08
- include description in tournament cli creation
- add new tournament + initial scheduled launch dates
- refs virtualcommons/planning#50
- isolate invite specific data from general tournament status which is
  now used to initialize the client store when tournament mode is on
- check invites in onAuth in tournament lobby
- included migration for renaming 'openbeta' tournament to 'freeplay'
  along with renaming other instances

Co-authored-by: Allen Lee <[email protected]>
- TournamentLobbyRoom now drains all connected clients when it allocates
  random groups of connected participants
- add pending group management + client cleanup logic to
  TournamentLobbyRoomState
- use lodash Fisher-Yates shuffle instead of hand-rolled random sort
  (which is cautioned against due to lack of random-ness, see
  https://stackoverflow.com/a/18650169/93370 for more details)
- replace maxClients with maxConnections throttling support in
  tournament lobby
- FreePlayLobby currently does not max out, but we may want to revisit
  that and include a check against total number of active participants
  and maxConnections in onAuth or canClientJoin
- consider moving getFilledUsernames and other autobot filling
  routines into FreePlay to prevent tournament lobby from creating rooms
  with bots
- reworked schedule/countdown components

TODO: add links and announcement banner to homepage

ref virtualcommons/planning#49
@sgfost
Copy link
Contributor Author

sgfost commented Oct 27, 2023

thanks for the matchmaking changes @alee. Dashboard is up and running, I'll put together an announcement banner + linkage tomorrow

ideally this would use text retrieved from a tournament/round on the
backend, a full description and round announcement are way too wordy for
a banner but we should communicate the main points. Consider a
shortDescription field in the Tournament
@sgfost sgfost changed the title Tournament mode Tournament lobby + dashboard Oct 27, 2023
@alee alee marked this pull request as ready for review October 27, 2023 23:26
Copy link
Member

@alee alee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

great work as usual @sgfost !

@@ -1,15 +1,19 @@
<template>
<div class="countdown">
<div class="countdown-block">
<div class="countdown-digit">{{ format(hours) }}</div>
<div class="countdown-digit" :style="`font-size: ${size}rem`">{{ format(days) }}</div>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

might consider putting this into a digitStyle getter that returns the string font-size: ${size}rem for now but could also add other custom styles?

Not blocking this merge, just for the future

@@ -55,7 +60,7 @@ export class AjaxRequest {
({ data, status }) => {
if (status === 200) {
this.store.commit("SET_USER", data.user);
if (data.user.isVerified) this.router.push({ name: LOBBY_PAGE });
if (data.user.isVerified) this.router.push({ name: FREE_PLAY_LOBBY_PAGE });
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we add another check to see if we should funnel them to the tournament dashboard instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh yeah I suppose that would be one way to fix it, though may be confusing to route to one or the other when both are active. I think routing to home is fine until there's a way to pass a next param to the login routes

- add getters for tstore access, feeding the consistency hobgoblin
- include timezone in toLocaleTimeString
- move logo style into portOfMarsLogoProps
- remove dead code, unused props and attributes, etc.
- guard against empty leaderboard errors
- add event description back to calendar-event
- build a single event object and reuse for multiple links
- improve :key usage though maybe we don't even need them anymore,
  see https://v3-migration.vuejs.org/breaking-changes/key-attribute.html
- 404 errors in the ajax plugin now redirect to HOME_PAGE, not
  FREE_PLAY_LOBBY_PAGE
- remove dead code + yarn style:fix
@alee alee merged commit 6ec3485 into virtualcommons:main Oct 28, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants