Casting to character in BT Task causing crash

This is an issue that is only happening while using 4.7.2 back in 4.6 it worked fine.

Here is my enemies attacking behaviour tree task.
In this image the bits that I have highlighted seem to be making the game crash as soon as they are executed. The ‘cast to mycharacter’ seems to work fine, but when i want to use it to do a custom event/change the player health the game (PIE and packaged) just crashes :frowning:

Also is there a better way for enemies to deal a specific amount of damage to the character?

Do you happen to have any callstack or log file for this crash?


Where do I find the log files?
Thought it might have been here D:\Program Files\Unreal Projects\Overdosed 4.7\Saved\Logs but can’t seem to find anything in the many log files.

Also would it be better to see the crash report for the packaged game version? You’ll have to tell me where that is too.

PIE would be preferable and just repro the crash, copy-paste here any info that pops up and attach the newest of logs in the Logs directory.

This is what came up in the crash reporter: MachineId:44A2C4BF4A2F1FCF81BD7AB524AB0251EpicAccountId:b072f3e306ab4edb9c0e02 -
This is the latest log file: Log file open, 03/17/15 18:22:05LogInit:Display: Running engine for game: Over -

and this is on 4.7.3 too

It looks like it’s the characters health that is breaking it.

‘MyCharacter_C_0’ is of class ‘MyCharacter_C’ however property ‘FloatProperty_1323’ belongs to class ‘TRASHCLASS_MyCharacter_675’

We were having a similar issue today. In an enemy BT we had a task for attacking the player, and inside of that all we were doing was finding the player My_Character, casting it to My Character, and subtracting health from the player. It would crash straight after the cast.

We are running a streaming perforce server which may be the cause of the issues. After it started crashing, we would just delete in the BT ‘get player health’ and ‘subtract damage’ nodes. We would remake those exact 2 nodes with the same values and it would fix the problem. Once we check the blueprint back in and checked it out again and re-ran the project again, we would get the crash again.

One work-around we did was created a function inside the NPC Blueprint, and inside the task we would call that function to subtract the health. I hope this helps you in some way.

We are using 4.7.3 as well.

Just tried your work-around and it works! No crashing! :smiley:

Thanks so much for the suggestion.

well actually that didn’t last long…
It’s crashing again but now it’s showing this in the logs:

‘Devourer_C_0’ is of class ‘Devourer_C’ however property ‘BoolProperty_1839’ belongs to class ‘TRASHCLASS_Devourer_879’

(Devourer is my enemy NPC)

Seems to be something to do with trashclass but can’t seem to find what this is :confused:

Hi LazyGames,

Our Blueprint developers were able to find and fix a bug that seems to cause this symptom. The fix is scheduled for the 4.7.4 hotfix. They would like to have a copy of your project just to double-check, so if you would like, we can do that.


The project is a bit too big for me to upload atm (even when compressed)
I’ll wait for 4.7.4 :slight_smile: Thanks.

Alrighty, please let us know if it does not fix the problem and we will continue the investigation.


Boo.Ours is still running fine luckily enough haha. Well at least now we know it could be a bug and hopefully gets fixed :slight_smile:

I am experiencing this same crash. In 4.7.5. Cast to MyCharacter class in Behavior Tree Task crashes. I am able to cast to Character, so it is just the cast to my new one.

Edit: As a note, remaking a new BT Task from scratch is working now.

Hi ,

Just to be clear, you are saying if you recreate the BT Task, then it works fine again? Can you post the crash callstack and log just so that we can be certain it’s the same? Just on the off this is a similar, but different issue.

Thank you.

Hello my game is experiencing a similar problem and I was wondering if I could get your help. Please notify me if you help me out with this problem.

Hello ,
My game is experiencing a similar problem and I was wondering if I could get your help. Please notify me if you can help me out with this problem.

Hi Willh313,

If you are experiencing this same issue, please provide more details for it here such as the crash callstack and logs. If you have a similar, but different issue, please post it as a new question to the Bug Reports section of the AnswerHub.


I actually fixed by moving up to 7.5 as the thread suggested. Thanks for your quick response though. I really appreciate it.