Config settings for BPs inheriting from Pawn

I’m trying to set up some config variables for my player pawn (a blueprint object), and I’m running into an issue where it just refuses to read values from the DefaultEngine.ini file. I have the Config Variable check mark ticked, and I’ve made sure that the section in the config is also correct, character for character. I have seen that blueprints that subclass other classes (Actor, ActorComponent, SceneComponent) do work. It would seem that this is a bug, but there might be some secret trick that I am missing. Any help on this would be greatly appreciated :slight_smile:

Hello vdwtanner,
I was unable to reproduce your issue on our end. I have a couple of questions that will help me narrow down the issue you are experiencing.

  1. Can you reproduce this issue in a new project?
  2. If so could you provide a detailed list of steps, so I can reproduce your issue on our end?
  3. Could you provide a screenshot of your issue?

Thanks!

Hi , I was able to reproduce according to the following steps:

  1. Create new blank BP project in 4.15.1

  2. Create a new BP that subclasses Pawn (TestPawn)

  3. Create a new float variable (Test) in TestPawn

  4. Mark Test as a Config Variable

  5. Compile and Save

  6. Open DefaultEngine.ini in the Config directory

  7. Add Section: [/Game/TestPawn.TestPawn_C]

  8. Add key=value pair: Test=123456789

  9. Save DefaultEngine.ini

  10. Close UE4

  11. Reopen project

  12. Open TestPawn

  13. Value of Test is still 0

139047-capture2.png

Just in the sake of completeness, I updated to 4.15.3, and this issue is still present.

Hello again,

Using the information you provided I was able to reproduce your issue. I have logged it for a report, which you can view here:

You can track the report’s status as the issue is reviewed by our development staff. Please be aware that this issue may not be prioritized or fixed soon.

You can workaround this issue however. One solution I took was to make a separate Actor Component Blueprint and made the variable in that blueprint then used the same steps in your repro, and this updated the value as expected. Then I added that Actor Component into the pawn and got the value that way.

Cheers!

Thanks for the reply! I ended up doing that same thing as a quick fix in the meantime. Obviously not ideal, but certainly better than nothing :slight_smile: