*Bump* Overridden Parent event called without a call from child. Bug? Only happens once
I'm new to Blueprints. I've got a parent class (AI_Enemy with Events: Wander, Idle_Wait, BeginPlay) and a child class(AI_Minion with Event: Wander). When I place breakpoints on entry to Wander, Idle_Wait, and BeginPlay, I hit the Wander Event of the child first of all. It executes on the child until it hits the AIMoveTo function and then execution jumps to the parent BeginPlay event. It executes there and calls into the parent's Wander function(why?) and runs until it hits the AIMoveTo function there. The next step into command I give will kick me out of debugging and give me the error "Infinite Loop Detected. Blueprint: AI_Enemy Function: Wander". First Question: Why does the Wander of the child get called even before BeginPlay of the parent? BeginPlay of the parent is the first place the Wander Event even gets called. Second: Why does the Wander event of the parent ever get called if it's overridden in the child class and doesn't have a call to the parent anywhere? Thanks for the help. I've been banging my head on this for a while.
And the Wander Event of the Child Class:
As i ynderstand it, a child class executes the functions it overrides, in its own class, and then if you specifically nake a call to the parent class' version of the function, then that one will run too. I am guessing that maybe the behavior trees or something natively calls that parent version of the overridden function.
answered Aug 12 '18 at 12:46 AM
Follow this question
Once you sign in you will be able to subscribe for any updates here