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 ?
asked Mar 18 '18 at 04:14 PM in Blueprint Scripting
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.
answered Mar 18 '18 at 04:20 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here