After my character dies, i destroy the actor. Now i am getting an error “attempted to access third personCharacter via property Player Ref but ThirdPersonCharacter is pending kill”. Image 1 is where the error is occuring.
Well, you do not remove the HUD when you destroy the player. I assume you call GetPlayerHealthPercent every tick? You could do one of the following (there are probably tons of other ways to do this):
remove the HUD widget first
set PlayerRef to None and add a check if it is set
add a bool “PlayerDead” to the HUD, set to true on death, and check that every frame
not destroy the player character, but hide it instead