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: Store player attributes in Dictionary instead of Array #165

Merged

Conversation

aronand
Copy link
Contributor

@aronand aronand commented Apr 16, 2024

Player attributes are accessed by name, thus storing them in a Dictionary makes more sense than in an Array.

These changes edit attribute storing, saving, and loading to use Dictionaries instead. An attempt is also made to make the code ever so slightly more readable by using more descriptive variable names where applicable.

Changes are tested in test maps and seem to function as intended.

Copy link
Owner

@Phazorknight Phazorknight left a comment

Choose a reason for hiding this comment

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

Sweet, thank you for this!
Approved.

@Phazorknight Phazorknight merged commit fe807eb into Phazorknight:main Apr 16, 2024
@aronand aronand deleted the PlayerAttributesAsDictionary branch April 16, 2024 16:11
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