Taking damage from First Person Projectile

Am trying to build an Endless Runner where you’ve to dodge bullets for which I used the default BP_FirstPersonProjectile from FPS template and a small gun that shoots them. The problem is am unable to cause damage to my player character (the default BP_ThirdPersonCharacter). I saw a few YouTube videos and tried implementing the Event Any Damage node but nothing even when I cast and try to decrease the health variable it doesn’t print anything. Any help would be greatly appreciated. Thanks.

There is a class called DAMAGE TYPE … use it to deal damage to others along with the “Take Damage” function.

Post a screenshot of your script

a small gun that shoots them

Assuming these spawn projectiles, show us how they deal damage to actors they hit.

tried implementing the Event Any Damage node but nothing even when I cast and try to decrease the health variable it doesn’t print anything.

Again, please show us something we can work with. If you could include the collision settings of the player’s capsule and the projectile’s collider, that would help a lot.

No casting or using Damage Type class is necessary for something like this.


In the most bare-bones scenario, it could look like so:

  • projectile:

  • player:

image



My setup is quite similar but doesnt work also I made the floor spawning as in the third image using a collision box it also bounces the projectiles off of it.

Am the same guy thanks, that account is new and doesnt allow me to upload pictures

Things do not add up here. You say projectiles bounce but they’re set to overlap all:

Could you clarify the hierarchy of the projectile and tell which component is responsible for the collision detection in the projectile. The component responsible for simulation and collision - the one interacting with the Movement Component - should sit at the root of the actor.


Providing the Pawn’s Capsule collision is set to the default Pawn, the absolute minimum for the projectile overlap to work would look like this:

The projectile would ignore everything but the Pawn Object Type and would not bounce off anything. Creating additional object types and channels is also an option if you desire more granularity.

1 Like

Thanks so much man that worked !

1 Like