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

Use correct leaderboard data #38

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

FairPlay137
Copy link

This corrects some issues found on the continue screen, as well as showing the timed mode high score instead of the story mode high score on the timed mode results screen.

loginTime := player.LastLogin
mainCharaID := player.PlayerState.MainCharaID
mainCharaLevel := int64(12) // TODO: remove testing
mainCharaLevel := player.CharacterState[0].Level // TODO: is this right?
Copy link
Owner

Choose a reason for hiding this comment

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

This is incorrect. The main character is fetched by getting the index of the main character by player.PlayerState.MainCharaID. The player struct has a helper function for this: player.IndexOfChara(player.PlayerState.MainCharaID).
Likewise, this applies to line 26, and lines 28 and 30 with player.IndexOfChao(player.PlayerState.MainChaoID).

Copy link
Author

Choose a reason for hiding this comment

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

I'll keep that in mind.

@fluofoxxo
Copy link
Owner

Newest commit looks good, will test a build soon.

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.

None yet

2 participants