-
-
Save codeforfun-jp/91e657d3bb28d3c0103c9945d2013abb to your computer and use it in GitHub Desktop.
CTB 6-6
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
// Pink | |
float pinkCenterX = pinkX + pink.getWidth() / 2; | |
float pinkCenterY = pinkY + pink.getHeight() / 2; | |
if (0 <= pinkCenterX && pinkCenterX <= boxSize && | |
boxY <= pinkCenterY && pinkCenterY <= boxY + boxSize) { | |
pinkX = -10.0f; | |
score += 30; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment