# Fix Camera View on Character Death

**URL:** <https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157>\
**Category:** Character & Animation\
**Tags:** Destroy, actor, unreal-engine, player, question\
**Created:** [November 2, 2015, 4:09am UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157 "2015-11-02T04:09:02Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![nmm131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@nmm131](https://forums.unrealengine.com/u/nmm131)\
**Post date:** [November 2, 2015, 4:09am UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/1 "2015-11-02T04:09:02Z")

</div>

Using a destroyActor → actor from class (character)  
my character is destroyed. My view through the camera, however, is removed. It seems the camera stops in its tracks, the view ejects out of the camera 5 feet, turns right 90 degrees, and stops right there.

How can I keep my view through the camera once my character dies?

I have two examples: one involves a camera that moves on its own and is not connected to any actor. It is my main camera. The same thing happens, my character dies, my view jumps out of the camera and turns 90 degrees.

My other example is a camera that is attached to my character. The same thing happens with the camera.

It cannot be due to the fact that the camera is connected or not connected to the character. How could I fix this?

Worst comes to worst…snatch view to another camera? How on death? I have death occuring in an actorBlueprint, where can I have the code in that to snatch to another setViewTargetwithBlend? Ideal if I could do this on any event of character death inside the level blueprint

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_087ae450](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_087ae450](https://forums.unrealengine.com/u/anonymous_user_087ae450)\
**Post date:** [November 2, 2015, 9:10am UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/2 "2015-11-02T09:10:26Z")

</div>

You need to change camera from the playercontroller bp. After death in playercontroller use function set target view with blend and use default camera actor or use “get all actor of the class”- on camera actor and get first camera.

---

<div class="post-metadata">

**Author:** ![nmm131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@nmm131](https://forums.unrealengine.com/u/nmm131)\
**Post date:** [November 2, 2015, 7:34pm UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/3 "2015-11-02T19:34:48Z")

</div>

How do I create the event for when my player is destroyed?  
Preferably inside my level blueprint so I can setViewBlendSpace for the new camera

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_bb0cd524](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_bb0cd524](https://forums.unrealengine.com/u/anonymous_user_bb0cd524)\
**Post date:** [November 2, 2015, 8:46pm UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/4 "2015-11-02T20:46:54Z")

</div>

Make a custom event like “onPlayerDeathEvent” and call it in whatever BP node you have that makes the player die. Then it will fire when the player dies

EDIT: You could add the “onDeath” BP’s directly where the player dies, but I recommend the custom event so that it doesn’t get too cluttery

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_087ae450](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_087ae450](https://forums.unrealengine.com/u/anonymous_user_087ae450)\
**Post date:** [November 2, 2015, 8:52pm UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/5 "2015-11-02T20:52:02Z")

</div>

1. Add to your character public bool variable “isDead” with default value false. When he dies set “isDead” to true.
2. In Level blueprint on event tick check if your characters “isDead” is true set to false and use set target view with blend function.

* * *

If you can’t understand i can show this with pictures.

---

<div class="post-metadata">

**Author:** ![nmm131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@nmm131](https://forums.unrealengine.com/u/nmm131)\
**Post date:** [November 3, 2015, 5:37pm UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/6 "2015-11-03T17:37:35Z")

</div>

I’m having trouble setting up the custom event and connecting a camera to set view target with blend. Any advice?

---

<div class="post-metadata">

**Author:** ![nmm131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@nmm131](https://forums.unrealengine.com/u/nmm131)\
**Post date:** [November 3, 2015, 10:59pm UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/7 "2015-11-03T22:59:51Z")

</div>

I created the boolean value in my level bp, using a branch node off of the eventTick it will set viewtargetblendspace  
But I can’t call my boolean true or false inside my actorBlueprint

I must put the boolean in my level bp so I can call it  
My only destroyActors are in blueprintActor classes so that is where I will set the boolean.

---

<div class="post-metadata">

**Author:** ![nmm131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@nmm131](https://forums.unrealengine.com/u/nmm131)\
**Post date:** [November 3, 2015, 11:36pm UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/8 "2015-11-03T23:36:02Z")

</div>

could you show some blueprints to help me get my boolean from my level bp to my blueprintActor?

---

<div class="post-metadata">

**Author:** ![nmm131](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@nmm131](https://forums.unrealengine.com/u/nmm131)\
**Post date:** [November 5, 2015, 1:47am UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/9 "2015-11-05T01:47:36Z")

</div>

If I have an actor in location of where player died, how can I hook this up to my setViewTargetwithBlend New View Target module?

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_087ae450](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_087ae450](https://forums.unrealengine.com/u/anonymous_user_087ae450)\
**Post date:** [November 5, 2015, 11:45am UTC](https://forums.unrealengine.com/t/fix-camera-view-on-character-death/337157/10 "2015-11-05T11:45:17Z")

</div>

You want to change view from character and it’s not correct , because you are destroying this character after view change. So do this from player controller BP. Good luck
