Hello there, i’ve encountered some weird error and can’t find solution to fix this.
So what i’ve got is:
Actor, that has two functions bind to OnActorBeginTouch and OnActorHit. The functions are BlueprintNativeEvent, so i can easily and fast create different functionality in Blueprints.
Base class implements these functions this way: spawn few other actors of different class and destroy itself.
Now, when i try to override on touch delegate, if i simply add Blueprint event which overrides function and leave it as is, i got desired result - nothing happens. As soon as i try to spawn other actor or anything like that - my native implementation being called, but the Blueprint overridden one - is not. One thing to note, i print debug string to the screen in my native implementation, and in the case described above - string also is not getting print to the screen, looks like native function being called without being called…
Another thing about Blueprint overriding:
I’m spawning actor via my custom function-wrapper, which takes location and rotation as input. So if i specify location by hand - it works fine, no native implementation is called, once i attach Get Actor Location node to the location input pin - it calls native implementation once again.
So there are few screenshots for better undertanding:
Works fine, nothing happens upon touch.
Works fine, projectile being spawned at specified location.
Does not work as expected, native implementation being called(without debug message being print)
Source code for the actor on pastebin:
[Header][4]
[Implementation][5]
Why not fully use blueprints for this since there’s nothing extraordinary in the C++ code?
Wanted to, but i was not able to override static mesh component properties of the blueprinted-actor which is based on another blueprinted-actor, in other words: i had no access to component added via Blueprint.