Under Review

Prefabs Lose Variables / Macro Reference

Xefier Games 1 month ago • updated by AiSard 1 week ago 13 1 duplicate

Bolt 1.4.1

Unity 2018.3.6f1

No matter how many times I revert the nested prefab it always resets the State Machine and Variables components to default settings making it unusable.

Bolt Version:
Unity Version:
.NET Version:

Duplicates 1

Under Review

Hi Xefier,

Is there any chance this is on a prefab that was created in a version of Unity before nested prefabs? If so, you would need to Reimport the prefab asset to fix the issue (see this section of the Known Issues).

This Unity Project was started in 2018.3

Something is very wrong in 2018.3, I had been working on a Macro half a day and there's nothing in the Macro at all now.

The project was started in 2018.3

Exacly same issue on our end but it's not happend only for prefabs but also for regular gameobjects. I just close and open scene and macro just gone from state/flow machine .... 

I had a Windows Update just before this happened and they've caused instability issues with Unity before, does this sound relevant to anyone else?

Other than that nothing has been updated, ported etc.

Upon further inspection, the problem might be unrelated to git. Object variables simply won't be applied to instances. Neither will the assigned flow or state macros.

This sounds very similar to the issues I'm experiencing. +1 to this.

Under Review

Hi Syver,

Can you post some simple reproduction steps to recreate the issue?

Hi everyone!

As always, clear repro steps is the only way I can track & fix this bug.

What exactly is resetting? How did you configure the prefabs and the variables? 

Please give a step-by-step list of instructions to trigger the bug from a blank scene/project.


I encountered the same issue. I try to describe how it happened.

1.) Made a GameObject and put prefab children inside it in the scene. (Parent object "BrickSpawnMachine" has no flow machine on it)

2.) Pulled parent object from scene in prefab folder. 

3.) Then deleted GameObject from 1.) from scene

4.) Pulled it later back from my prefab folder.

5.) Variables and Macros from the child prefabs (BrickSpawner) are missing

The child prefab itself (BrickSpawner) is still alright on itself. But the variables and macros ont BrickSpawner prefabs inside the BrickSpawnMachine prefab are gone.


Hi Limpertus,

I tried reproducing your exact example, but variables seem to persist at every step of the way. Here's a video of it, tell me if I did anything wrong:

Ok, looking at your video, I found out that I forgot one important detail. I captured a video too, so you can see my workflow (may be better than writing too much text). Hopefully it isn't a Bolt problem, but only me being too stupid too understand the new nested prefab workflow correctly :D

While slightly different, I think mine is a related issue, but in 2018.3.7f (1.4.2 net4) creating a variant prefab would have the variant lose Object Variables and the State Machine reference, no matter how many time you apply/revert changes.

Updating to 2018.3.12f1 seems to have fixed it, putting down repro steps in case it helps.

1. Make Cube Gameobject. Attach Flow/State Machine. Set an Object variable test = 10
2. Drag in to Project to make Prefab
3. Change value of test to 200 or something
4. Drag in to Project and make it a Variant Prefab.
5. (I forget if you need to instantiate a new Variant or if it affects the current one in the scene)
6. Check Variant. All object variables are missing. Flow Macro reference may be missing, or the component may be empty altogether.