Hello Community,
I'm making a top-down shooter, and so far if I click left-button is down, it should produce a short burst of 3 bullets then stop. I got it working this way:
.. Player spawns bullet#1, wait.02sec, spawn bullet#2, wait.02sec, spawn bullet#3
I'm not sure if there's a better way that this... perhaps with instance variables?
However, I want to prevent excessive clicking on mouse, which spawns lots of bullets.
so...
- 1 click with produce 3 short bursts of bullets.
- excessive clicking will be ignored.
I tried a few things but was unable to achieve this.
Help please
Thanks,
Roberto