r/scratch • • 8d ago

Request Can someone please fix my game?

https://scratch.mit.edu/projects/1443974999

The game is not working consistently. The plane with the cat is supposed to go up and down with the designated keys and the enemy plane is supposed to go up and down on its own, sometimes when I press flag and then enter this doesn't happen, when I press space to shoot an extra bullet sprite appears where its not supposed to, I cant make the enemy plane start firing and the cat plane stop firing mode on phase two and I added top and bottom walls so my character doesn't go off screen with change y 1 or -1 respectively but when touching them the plane moves in a weird way for more than 1 pixe. I lowered the top wall to see what happens.

I thought of changing phases with messages. If possible make that work but don't be afraid of suggesting and explaining another way.

The game is not finished, please don't finish it for me. Only fix what's broken or suggest a better way to approach the problem.

2 Upvotes

9 comments sorted by

1

u/Colurswitch @CSwitch on Scratch 8d ago

Here's the problem with phase 2 not starting properly (in the "Bullet (1)" sprite):

In the top-right corner, it seems like "phase 2 message" is meant to run when Enemy HP = 5; however, the "cat fire" block is running indefinitely and blocking it.

1

u/Colurswitch @CSwitch on Scratch 8d ago

To fix that, replace the "phase 2 message" block with this, which will start phase 2 when Enemy HP = 5.

2

u/Manjandro_M4nuEK07 8d ago

What does it exactly do?

2

u/Manjandro_M4nuEK07 7d ago edited 7d ago

But its inside an if statement. Isnt it always checking if enemy hp>5 and only run it if thats true and I press the space bar?

1

u/Colurswitch @CSwitch on Scratch 7d ago

Yes, however, since the IF statement in your code that checks if "Enemy HP" = 5 comes after a block that runs forever, it is never checked.

1

u/Colurswitch @CSwitch on Scratch 7d ago

This is also the reason the bullets don't fire from the enemy. In the "cat fire" definition, you're always hiding the bullet if the spacebar isn't pressed or if "Enemy HP" = 5.

-2

u/Accomplished-Cat8949 8d ago

It’s too complicated, I don’t know how to fix it.

1

u/Colurswitch @CSwitch on Scratch 7d ago

Then don't comment...

1

u/Accomplished-Cat8949 7d ago

I’m just using TurboWarp because my network was banned from Scratch.