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

prod(future): Game credits / tokens + limits #21

Open
sudojunior opened this issue May 15, 2022 · 2 comments
Open

prod(future): Game credits / tokens + limits #21

sudojunior opened this issue May 15, 2022 · 2 comments
Assignees
Labels
documentation Improvements or additions to documentation enhancement New feature or request

Comments

@sudojunior
Copy link
Member

sudojunior commented May 15, 2022

This is would be a core implementation to limit how many games can be created in any guild per user.

The idea is that a player gets n number of credits per timeframe (be it hour, day, week or month) thereby allowing a routine restock once the supply for each user is replenished. This can extend further into specific guilds, but I'm not sure how long it'll be before it becomes unnecessary or tedious before end-users decide to find another bot or attempt to host it themselves and override the limits.

@sudojunior sudojunior added documentation Improvements or additions to documentation enhancement New feature or request labels May 15, 2022
@sudojunior
Copy link
Member Author

sudojunior commented May 15, 2022

If the deployment is configured to run at maximum capacity, Discord would be the only blocker to it's process:

  • 50 channels per category

    50 lobby channels at any given time

  • 1000 active threads per guild
  • 5 messages per 5 seconds per server (maybe not?)
    • 50 messages per 10 seconds globally.
  • 10k requests (resulting in error code 4**) per 10 minutes
  • 50 requests per second

Of course the objective is not to push this to the absolute limit, but it is useful for gauging service usage as well as scaling the 'cost' of these credits appropriately to reflect that.

@sudojunior
Copy link
Member Author

Example projected costs

This includes credit costs for both users and servers / guilds without any idea of what limits should be in place or the appropriate cost of each action.

Any destructive actions are intended to deter unless absolutely necessary.

  • Hosting a new game = 5 credits from user, 1 from guild?
    • Would starting a private / invite only game affect this cost? (i.e. double credit cost, to emphasise its purpose)
  • Joining a game = 1 credit (public); 3 credits (private / invite accepted) from user

    I can be cruel here and suggest the possibility that sending a request to join could also cost credits, but that would wager into a system of bias and abuse of each other's credits... so I'd prefer not.

  • Leaving a game early (before they have been eliminated) - 2 credits from user
  • Kicking a player from the game - 4 credits from user (game host)
    • Starting a vote to kick a player - 2 credits from user
  • Ending game early as host - 10 credits from user, 5 credits from guild

@sudojunior sudojunior self-assigned this Jul 13, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant