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

[REFACTOR] - Revise the game tracker and matches result #1011

Open
tvillegas98 opened this issue Dec 17, 2024 · 0 comments
Open

[REFACTOR] - Revise the game tracker and matches result #1011

tvillegas98 opened this issue Dec 17, 2024 · 0 comments

Comments

@tvillegas98
Copy link
Contributor

There are a few things to revise here:

  • The game tracker is mainly focused on the battle game mode.
  • In the game tracker, we have a position_on_death, while in the game state, the player's match position is tracked in a different way.
  • Prestige is hardcoded! We should refactor this.
  • There's a TODO note mentioning that the death count works only because players die just once 😆. This is no longer the case.

Also, when anytime we're calculating or putting the position of the player in a match, we do this:

    {client_id, _player_id} =
      Enum.find(game_state.client_to_player_map, fn {_, map_player_id} -> map_player_id == player_id end)

Maybe we can insert the client id in the player's structure and avoid having to do this. Or invert the map so we have the player as the key and the value as the id

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

No branches or pull requests

1 participant