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

Improve code quality of Breakout game example #2094

Closed
wants to merge 47 commits into from
Closed
Changes from 28 commits
Commits
Show all changes
47 commits
Select commit Hold shift + click to select a range
cad807b
Cleaned up time step by moving to a separate config
alice-i-cecile May 4, 2021
168f33f
Organize resources and components into modules
alice-i-cecile May 4, 2021
930f6cf
Move background color to configurable const
alice-i-cecile May 4, 2021
9fbe206
Use init_resource for the Scoreboard
alice-i-cecile May 4, 2021
8de74a8
Split setup into many small startup systems
alice-i-cecile May 4, 2021
858a7ab
Added marker components
alice-i-cecile May 4, 2021
bdd9c9c
Clarity
alice-i-cecile May 4, 2021
1d82952
Refactored Wall code to reduce mess
alice-i-cecile May 4, 2021
e99feda
Cleaned up bricks logic
alice-i-cecile May 4, 2021
1193669
More color constants
alice-i-cecile May 4, 2021
eb8c8f0
Extract Paddle and Ball magic numbers
alice-i-cecile May 4, 2021
57976a6
Extract magic numbers from Scoreboard
alice-i-cecile May 4, 2021
8b154b5
Added kinematics system
alice-i-cecile May 4, 2021
2c99de0
Cleaned up ball and paddle movement
alice-i-cecile May 4, 2021
88e0eac
Clean up scoreboard_system
alice-i-cecile May 4, 2021
3e864a6
Add starting velocity to ball
alice-i-cecile May 4, 2021
6835d60
Rename add_* startup systems to spawn_*
alice-i-cecile May 4, 2021
120bbdf
Reduced system naming redundancy
alice-i-cecile May 4, 2021
9112742
Cleaned up collision function
alice-i-cecile May 4, 2021
4768e9b
Respect ownership rules...
alice-i-cecile May 4, 2021
803c0e7
Moved many consts to local variables
alice-i-cecile May 4, 2021
400f3a3
Add missing marker component
alice-i-cecile May 4, 2021
3d009c2
Improve comments
alice-i-cecile May 4, 2021
6e37cf4
Removed magic number
alice-i-cecile May 4, 2021
be14d7a
Fixed paddle input
alice-i-cecile May 4, 2021
76c6fba
Collision should always run before kinematics
alice-i-cecile May 4, 2021
c970378
Fixed walls
alice-i-cecile May 4, 2021
658a8c6
Point to non-duplicate issue
alice-i-cecile May 4, 2021
9a83235
Fixed scoreboard text formatting
alice-i-cecile May 4, 2021
49e7070
Whitespace
alice-i-cecile May 4, 2021
c5fa685
Typo fix
alice-i-cecile May 4, 2021
225c143
Reordered systems to fix input lag
alice-i-cecile May 4, 2021
974e602
Swapped to for_each loops
alice-i-cecile May 4, 2021
3390742
Refactor to BrickBundle
alice-i-cecile May 4, 2021
ad1636e
Prettier glob imports for CONFIG
alice-i-cecile May 4, 2021
7a7da6e
Const cleanup
alice-i-cecile May 4, 2021
2aa0742
Use spawn_batch to create many bricks
alice-i-cecile May 4, 2021
680a251
Const vec2 configs!
alice-i-cecile May 4, 2021
0655325
Add useful FIXME notes about out-of-scope work
alice-i-cecile May 4, 2021
acfbde1
Move PADDLE_BOUND to config const
alice-i-cecile May 4, 2021
d3c0901
Improved comments
alice-i-cecile May 4, 2021
bd0ab2b
Added const Transforms
alice-i-cecile May 4, 2021
f40c69d
Satisfy clippy by removing redundant clone
alice-i-cecile May 4, 2021
46294c1
Add comments explaining system order rationale
alice-i-cecile May 8, 2021
bd73201
Added exit_on_esc_system
alice-i-cecile May 9, 2021
d33564e
Add delta_time scaling to paddle input
alice-i-cecile Jun 17, 2021
1be6794
Add paddle_input to fixed time step system set
alice-i-cecile Jun 17, 2021
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Loading