+ 5
Why the second red block didnt get to the top again?
once again help pls😅 https://code.sololearn.com/W8HXrbOFOD1l/?ref=app
4 ответов
+ 9
This comparison (line 60)
if(aPosY == HEIGHT-20){
Is too specific (expecting a very accurate scenario)
If you set it to
if(aPosY >= HEIGHT-20){
it will work
probably better to set it to
if(aPosY >= HEIGHT){
also it seems that the score increment only occurs once (first time)
probably another condition which is too specific
+ 9
Nahh, not a genuis, just encountered the same issues at some point ;)
+ 2
Oh Yesss!! Thanks Burey! You are a genius!👍👍👍
+ 2
Okay! Thanks again Burey!👍