Prototype: Scary Vec2s and Nice Sprites#2219
Draft
pushfoo wants to merge 29 commits intodevelopmentfrom
Draft
Conversation
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TL;DR: Proof we can
Vec2all*Spritewithout destroying the universe![ Obligatory Skrillex Noises ]
Note
The remaining pyright issues belong in #2183
How to try it
In your Arcade clone
git checkout upstream/scary-vecs-and-nice-spritesor however you have your remotes instealledpip install -I -e .[dev]In your Project
For the latest unstable version:
arcade@git+https://github.com/pythonarcade/arcade/arcade.git@scary-vecs-and-nice-sprites#egg=arcadeYou can also pin specific commits using a zipball link, but that's more convoluted.
Changes
BasicSpriteand subclasses, the following are nowVec2:.sizeis now aVec2backed by._size.positionis now aVec2.scaleis now aVec2_widthand_heightare now compatibility properties for any subclasses we missedWhat's not changed
Anything outside the sprites really. Seriously. There's a sound tweak to get it to pass and run, but otherwise, not even tests.
Current Code Quality
Already done:
Sprites pass:
pytest tests/unitpyright./make./py format+ruff check arcadeOtherwise, no guarantees:

Follow-up Work