Help with sprites not shooting

spaceshooter_testexplos.aia (248.1 KB)

so when i shoot in my game theres times when bullet sprites spawns but seems like it gets stuck to my ship and sometimes ill take double dmg and sometimes enemy explosion image dosent disappear wondering if anyone know solutions already tried everything i can think of. thanks :slight_smile:

If you are asking for help, I recommend you to make it as easy for others to be able to help you ...
You probably will get more feedback then...

which means in your case post a screenshot of your relevant blocks...

To download the aia file, upload it to App Inventor, open it, do some bug hunting for you, etc... this takes time, and most people will not do that...
Thank you.

Taifun


Trying to push the limits! Snippets, Tutorials and Extensions from Pura Vida Apps by icon24 Taifun.

Will post tommorow thanks :slight_smile: gotta clean it up a lil bit messy there :smiley: first project so

Read about 'sprite cannibalism' How do I stop more than one sprite being dragged at the same time (sprite cannibalism) - #4 by SteveJG

and


i thought sprite cannibalism only affects on drag events? but it sure feels like they wont get past my ship sprite will try that out thanks hmm there is no touch down or drag events so not sure thats it gotta be something with bullet spawning for 0.5sec get stuck under my ship and then disappear only dragable thing is my ship

I think I need To set 12 clocks for my bullets so they wont try insta spawn again too bad there isint Block that u can just set delay 500ms example

When you find your self with too many clock timers, consider setting up global lists of deadlines for the different component events.

Each list is devoted to a different action, like respawn, and its items are pairs (deadline in Ms, component)

Service the lists using a fast clock.

Can I setup 1 clock for my 12x bullet like when "bullet 1" hits target/reach edge it cant spawn again in 500ms same with bullet 2 3 4 onwards? If so Is there any example :)?

Here are some sample apps:

Bullet cloud:

exercise

(Wrong time scale for your app, but based on similar ideas)

Yes, but it would need a bit of time to code after I do my sweep of easy board answers.

I Will try if I can figure somethung from these thanks :slight_smile: I hope they get stuck because of no timers :smiley:

I don't see any errors when I run your app on my phone in the Companion.

I am reluctant to 'fix' something that works well.

when u shoot alot it starts to get bullets stuck on ur ship u press shoot but bullet wont go off sometimes kinda hard to notice but its there sometimes even 5 shots and no bullets go out, asteroids instantly destroys at spawn too sometimes hmmm i think my code tries to shoot all 12 at once so whats why they get stuck

here with boss can see easily his big bullets get stuck in his eye saw even with companion app

the first bullet my ship does the same

got it working 90% better when did set after "sprite visible false" i also did "sprite speed 0" i quess when sprites turn invisible they still go ahead or aint truly invisible not 100% fix but happens pretty rarely now :slight_smile:

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.