Changing the default AI controller class

@ben
Maybe I missed something in this lecture, but Ben never actually changed the tank’s default AI controller class to be the newly created BP version, right? So if the blueprint value is changed later, it won’t actually override the C++ default value.

1 Like

Hi there, I must have done for it to work no? Maybe I didn’t make it clear enough. You can check my project state as it is at the end of each video via the link in Resources.

Hi Ben,
I paused the video early and while setting it up myself I forgot to assign the BP controller to the AI tanks and I scratched my head a bit when the C++ default acceptance radius value wasn’t overwritten by the blueprint class. I figured it out before I restarted the video because something was obviously wrong, but since you tweak the value directly on the spawned AI controller (which is still the C++ class) and then updated the code with the sensible default you never really saw the mismatch. (Except early in the video, you get 3000 on the spawned controller but had already set 15000 in the BP).
In the end, it’s pretty neat to be able to tweak “EditAnywhere” values run-time like you do in the video, even without creating a BP class.
Cheers,
-Jan

1 Like

It is true, Ben didn’t notice but he created the TankAIController_BP and never assigned it as the default AI for the tanks, I was going to mention that, there is no problem since he changed the default range on the C++ as well but if a designer comes and tries to change the value on the BP he will not be able to see any difference :stuck_out_tongue_winking_eye:

1 Like

Privacy & Terms