Announcement

Collapse
No announcement yet.

Apply dammage to a VRPawn

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Apply dammage to a VRPawn

    Hi I am trying to apply damage to a VRPawn for steamVR but I'm not having much luck.

    Click image for larger version

Name:	DamageVRpawn.JPG
Views:	1
Size:	111.8 KB
ID:	1182835

    This is the health and damage I have set up in the VRPawn. I checked it with a keypress to apply damage and it did work but when I use the event any damage It's not working well.

    Click image for larger version

Name:	DamageAI.JPG
Views:	1
Size:	44.9 KB
ID:	1182836

    This is set up in my AI when I use the get player pawn it seems to cause damage as soon as its spawned into the world. It doesn't matter if it is overlapping the pawn or not. When I take it out no damage is caused to the pawn...

    Click image for larger version

Name:	VRPawn.JPG
Views:	1
Size:	62.4 KB
ID:	1182837

    I'm wondering is that because the event any damage doesn't know how to apply the damage to the pawn because it doesn't know what to overlap? Is that how event any damage works? That it has to overlap a 1st or 3rd person mesh in the viewport because the VRPawn doesn't have a character mesh.

    #2
    Two things I can think of. Either the collision like you said because VRPawn doesn't have a mesh. Fix this by adding a capsule collision. Make sure your overlaps are actually firing by firing a print screen when you want your event to trigger.

    Once you confirm that you are correctly overlapping and it's triggering, if you're still not taking damage, the reason might be because you must drag off your Get Player Pawn and do Cast To VRPawn, then do apply damage. Not 100% on that one, it's probably the collision thing.

    Comment


      #3
      I've created the capsule collision but how do I tell the game that when event any damage occurs I want it to occur because the AI box collision overlaps the capsule collision or does that happen automatically when I put in a capsule collision in which case that didn't work.

      Comment

      Working...
      X