Announcement

Collapse
No announcement yet.

Thirdperson Camera-Capsule overlapping event only occurs when Character is moving

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

    Thirdperson Camera-Capsule overlapping event only occurs when Character is moving

    I'm not entirely sure this is the best place to ask this. If there's a better forum to ask this question, let me know.

    I'm messing with the Third Person template and I want to make the mesh invisible when the camera is too close to it (for example, when the character is too close to a wall and the player rotates the camera and starts seeing the interior of the mesh). I attached a sphere collider to the camera, set it to overlap all dynamics, query only. Then I set the collision presets of the character's capsule to custom and to overlap the camera. Finally, I added a OnComponentBeginOverlap to the Sphere, but the overlaping with the capsule is only fired when the character is moving. I also tried to add the OnComponentBeginOverlap in the Capsule, but still only happens when the character is moving.

    The image shows the moment I want the overlap event to happen.

    I found this answer https://forums.unrealengine.com/deve...standing-still explaining about the object type of the capsule. When it is set to Pawn, this prevents the collision event to happen. I tried every other category but the overlap only occurs when the character is moving.

    Any idea about how to solve this problem?


    Click image for larger version

Name:	CameraCollision.jpg
Views:	229
Size:	73.6 KB
ID:	1716891

    #2
    Its a known bug / glitch. One solution is attach hidden mesh / collision sphere to camera iirc...
    Probably needs custom channel setup to avoid colliding with anything but character capsule.
    You should find a complete solution on AnswerHub if you search there or some search page....

    Comment


      #3
      Hi Clavos, thanks for your answer and sorry it took so long to reply. About your suggestion, I'm already doing the collision component on the camera (the screenshot shows this). I've tried to set the channels and check the collisions between the camera and the capsule collision of the pawn. I've searched the AnswerHub using "Pawn Camera collision" subject but, so far, no post was useful. Do you have a suggestion for which subject I should search? And thanks again

      Comment


        #4
        About your suggestion, I'm already doing the collision component on the camera (the screenshot shows this). I've tried to set the channels and check the collisions between the camera and the capsule collision of the pawn. I've searched the AnswerHub using "Pawn Camera collision" subject but, so far, no post was useful
        Its actually more involved than that. Study all the solutions here....

        Comment


          #5
          Thank you very much.

          Comment

          Working...
          X