Skip to content

Merge Rect and Rectf classes. #3236

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

tylerandari13
Copy link
Contributor

In honor of Supertux week, I have decided to contribute something of a decent size. This Pull Request merges a lot of int and float duplicates in Supertux into single classes with templates and using. These classes include:

  • Rect and Rectf
  • Size and Sizef
  • Vector and Vectori (technically it was added, but still)

The float variants of all of the classes were prioritized because they are more up-to-date than the int versions. This means Rect now has some asserts that weren't there before, and it has caught a couple of oversights in a few places... aaand thats why its still a draft PR. I need to finish fixing a bug in the tilemap code. I am releasing this as a draft so that things like codestyle can start being checked.

@tylerandari13
Copy link
Contributor Author

I forgot to mention in the description that I also replaced the left, down, up, and right properties with a function instead lol

@Hypernoot
Copy link
Member

Size_t is not a good name, as it can be confused with std::size_t.

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