whats your current blueprint look like? maybe we can modify it to work. basically you are going to need some flow control to determine whether the projectile can be fired. your going to want to have a branch that is connected to something like : get ammo → ammo > 0 → branch. so it will say is the ammo greater than 0 if true then you can fire, if not you cant fire.
When I pickup objects in the world I want to add 1 ammo to my projectile, which needs to be at 0 by default, and when he throw one projectile it drop by one
Hi guys. I have a ThirdPersonCharacter_BP, one PickupObject_BP and one ProjectileBP. When I pickup the PickupObject_BP I want to add 1 ammo to the ProjectileBP. When the game start, ProjectileBP need to have 0 ammo by default.( so it cannot be fired) and add 1 when PickupObject_BP .
So far, when I PickupObject_BP it disappears but my ProjectileBP can fire infinite Projectile no matter what.
Any clues ?
The only thing is that the player has 1 ammo when it begin. How to set it to zero ?
Nevermind I just had to put it to zero. thank you man you’re the best!
to control if the bombs can be spawned and eliminate them being spawned infinitely just do a basic check either at the input or at the event (like in the picture below). the method used is as described above.
glad to know it helped. got your homework assignment all done now?
Actually not at all. We have to create an entire prototype! If you want to be part of the team we can give you credit ( you will already have credit btw) since it is a student project. Our game has been presented to Ubisoft and have received the approval.