-
Notifications
You must be signed in to change notification settings - Fork 312
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add .rgb properties + tests for Color, Sprite, and BasicSprite (#2060)
* FriendlyGecko's initial Color RGB PR * Updated the color setter so that it does not change the current alpha * Updated it to check for use arcade.Color * Added an isintance check to the len3 check and moved those before the len4 check. So now if the user does a tuple of 3 (ie (255,255,255)) or uses the arcade.Color type (i.e. arcade.Color.BLACK) it will just reuse the old alpha. * Demo 1 * Added deeper RGB class * cleaned up RGB * Imports + clean up .rgb property * Revert BasicSprite.color changes * Revert RGB type since 0 tests + conflicts w/ existing type alias * Revert whitespace change * Rephrase BasicSprite.rgb docstring * Revert sys removal * Revert typing import noise * Revert BufferProtocol change * Add Color.rgb property * Add quick tests for Color.rgb property * Add tests for BasicSprite / Sprite .rgb property * Bug/typo fix + test tweaks * Fix typo in color type tests --------- Co-authored-by: FriendlyGecko <68018798+FriendlyGecko@users.noreply.github.com>
- Loading branch information
1 parent
42c5419
commit d4f61e1
Showing
4 changed files
with
117 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters