When i hold left mouse button (fire/shoot) i only spawns one projectile. But i can’t manage to continuously spawn projectile until i let go of LMB.
Edit: Line trace works fine, just the projectile isn’t working as i want it.
When i hold left mouse button (fire/shoot) i only spawns one projectile. But i can’t manage to continuously spawn projectile until i let go of LMB.
Edit: Line trace works fine, just the projectile isn’t working as i want it.
You could do it 2 ways:
Set Timer by Event Node
Set Timer by Function Name Node
If you have any other questions feel free to ask, I will answer as long as I am knowledgeable about it.
Unfortunatly it didn’t work. There are no projectiles spawning, and the first tap of LMB doesn’t shoot.
It’s night here currently and I’m on mobile
Could you try it when the looping boolean is true?
In my project that kind of setup is working
Is the blueprint you sent is in a character blueprint or an actor?
You could check that things first. I will help you again first thing in the morning.
Good luck and sorry if my first answer didn’t work out.
As I have checked the rate of fire should be none zero and it worked in mine
So i’ve retried but it still doesn’t work. it just spawned one projectile after like 3 bullets when holding LMB
And the blueprint is in character BP, btw i have no function for the projectile, it does it all in the character blueprint
Opening Unreal now and trying it again.
“btw i have no function for the projectile, it does it all in the character blueprint”
That’s fine
Something seems to affect your function, just want to ask where does the last branch execute again into if you still have it on your latest logic.
Try to remove that connection and try again that looks like an infinite loop
ok i gonna try it
I’m sorry can’t think of anything else that would prevent you from doing it.
What you could do last is check your branches put breakpoints on them (F9) and check variable states so that your logic is not flawed.
Also check variable default values they might not be set to the one you need (ex. Ammo might have only 1 bullet).
Check the flow of your logic using Step Into (F11) after breakpoint hit.
As you can see in my project it is working
You could put breakpoints on your logic so you could check the states of your variables something might be wrong there.
it goes all the way back to the branch where it checks if ammo is = or less then 0
Still doesn’t work, when i hold LMB the shoot event only calls once
okey, thanks anyways
Here’s all 3 firing modes … Single, Burst, Auto … each as an event.