Remove loading times

Lazlo Bonin (Lead Developer) 4 years ago updated 4 years ago 64 2 duplicates

I'll try to remove the loading times for unit caching and codebase analysis by caching the result in an asset and simply loading it with the editor.

On the downside, you will need to manually go through a small dialog to update the set of unit options after importing a third-party plugin or modifying your custom scripts. I'll take that occasion to make the Assembly Options and Type Options project settings more evident and better documented.

This may seem simple, but it's actually quite a big refactor! I'll try to get it done this week, fingers crossed!

Bolt Version:
Unity Version:
Scripting Backend:
.NET Version (API Compatibility Level):

Duplicates 2

This is currently the main culprit in my opinion. I have a beefy machine (intel 6700K, 32GB RAM, etc) and on a test project with a simple cube rotating, I get a 2-3 second delay when I press Play. Without Bolt it's instantaneous.

The Graph, Flow Machine and Variables inspector show a loading circle during this period.

Hope you can do something about it! Any how, incredible work!

Thanks for the feedback. It's helpful for me to know that for you, the delay occurs before these windows are done showing the spinner, and helps me pinpoint some causes of lag better. I'll do some heavy profiling in these areas and see if I can optimize anything.

Unity Ver-2107.1.0f3
iMac MacOS Sierra  Ver- 10.12.6 (16G29)
iMac (27-inch, Mid 2011)
Processor 3.1 GHz Intel Core i5
MEM 4 GB 1333 MHz DDR3
Graphics AMD Radeon HD 6970M 2048 MB
Unity running from a USB SSD drive

In th example Flow chart above from press play in editor to play in seconds over 3 tests - 18.39, 17.70 and 18.42.  Edit: On par with the below speeds after 2nd round of testing. 

In th example State chart above from press play in editor to play in seconds with 3 over -10.29, 13.69 and 14.49


Full Caching process when entering edit from play in seconds over 3 tests - 34.54, 36.62 and 37.40

This is on one of my systems, I will test from the others and post. Obviously this iMac is not a killer rig, but many devs will be using lower end specs so anything to reduce the load times is helpful.


Just a heads up to let you know that I've started profiling and thinking of optimizations.

I'll take the day off (it's Sunday after all!) but I'll be working on it further this week.

I am not sure if it is specific to the Mac version on Unity, but on my MacBook pro it is essentially unusable.  The delay you describe is too painful to be productive.  Works pretty well on my Windows 10 desktop.  A little more power and memory there, but this is noticeably slower than other features in Unity3d, from a relative perspective.

In a potentially related note, when using a Mac, the context windows for searching for a node are constantly resizing as you attempt to choose a node from the list (since the "hints" at the bottom of the list are forcing the panel to resize from the center, instead of top anchored, as on windows).  Also, right clicking with the trackpad is ignored in the graph editor window.  It works everywhere else in Unity3d editor during the same session, just not in the graph editor.  This makes is impossible to create a new node, without dragging a wire off an existing one.  In the short term, I'd be happy with an "add node" button on the graph editor, or even a hotkey.

I hope this is helpful.  Pretty solid tool so far.  Just need a few bugs ironed out.

Hi James, 

Thanks for the feedback and the kind words. When we're talking about delay here, are you referring to unit caching or the "freeze" when entering playmode? These are different issues and areas to optimize.

For the right-clicking issue, what happens if you change the control scheme from Unreal to Unity in the preferences panel (Tools > Ludiq > Editor Preferences... > Graphs)? The Unreal control scheme (default) is more convenient for desktops, but less suited to trackpads. 

Hi Lazlo,

I am referring specifically to the unity caching.  Given that the fuzzy finder opens dozens of times in a session, waiting up to thirty seconds is rough.  The "play freeze" is annoying, but I would take it over the caching.

As for the right clicking, I have tried both control schemes.  Unity is better on the trackpad for panning the graph, but right click doesn't work on either scheme.  This is further difficult, since the mac uses "ctrl+click" to right-click.  Since Bolt uses "ctrl+drag" to create groups, this seems to override the right click.  This makes the trackpad totally unusable on the MacBook Pro.  

Thanks for clarifying. Version 1.0.1 will not address the loading times yet, but it's my next priority.

I believe the usual control scheme for Mac OS is to replace most instances of "Ctrl" on Windows with "Cmd", am I right? If that's correct, I'll change group creation to Cmd+Click on Mac.

In the mean time, to trigger the menu on the trackpad, you can use the default multi-touch action of tapping with two fingers to right-click.

It would also be handy if you could simply drag to select a group and on realize be given the option to create the group as opposed to CMD/CTL drag

You can already start holding Ctrl after you've started selecting to turn the lasso into a grouping tool. Or is that not what you mean?

Yeah. Being lazy. Kinda would like to skip the whole holding part. I frequently work one handed.

you are correct.  normal convention is "Cmd"

As to you other point, two finger tap is also not working.  basically, no kind of right click on the mac trackpad.

Two-tap works here. Do you have secondary click enabled in your trackpad preferences?

I'll updating the control scheme for v.1.0.1 to use Cmd everywhere and fix Ctrl+Click.

hmm.  that is really strange.  maybe it is just me.  I do have secondary click enabled.  The odd part is that it works in the panel right next to Bolt, but not in the Bolt graph editor panel itself.  maybe a conflict with the mouse driver I have installed.  who knows.

I can attest to that as well, the fuzzy finder will resize and cause an almost flickering like screen when hovering over nodes with many options making it very difficult to see or choose the one you need, of course making note of where you open the finder will help but not convenient. Not an issue on my iMac, but on on my Air, with the much smaller screen, becomes problematic in picking some nodes.


I have a pretty beefy machine (i7 w/ 16 GB of ram) and I see a hang of 1-2s when pressing play on Windows 10. I'd love for it to not have to recache every time or I had a way to explicitly tell it to recache. 

Thanks for the feedback. I will definitely address the caching issue before the hang issue.

That is welcome news and a small conseeion to speed up that process. Ty. 

Under Review

Bad news, everyone. :/

I implemented the solution I was planning (caching the options to a file and loading them, instead of recalculating them every time).

It turns out that loading the file with 20k+ options is exactly as long as calculating the options for 20k+ units (10 seconds on my machine), meaning the last two days of work on this are pretty much moot. FullSerializer isn't the fastest deserializer, and at the moment I'm not sure at all how I'll be able to fix this issue.

I'll get some rest and see if some miracle solution comes to me. Rest assured this remains my #1 priority, but I'm at the end of my wits at the moment.

Maybe you can collaborate with developers of product: http://sirenix.net/odininspector? It's has own serializer, maybe it's more powerful and fast then FullSerializer.

Why does it have to load them more than once?  Shouldn't that only be an issue when we open the project, or does Unity work in some other way somehow?


It's actually because Unity reloads all assemblies whenever you enter play mode. That means that all the memory is cleared, and every script, window, variable or whatnot is reset. 

Unfortunately, the only way to preserve the data across assembly reloads is to serialize it (save it to a file on disk) before the reload, and deserialize it (load it from the file) after the reload. This works OK for small things like settings and whatnot, but when you have a massive database 15 MB of tens of thousands of units, it takes too long.

FullSerializer (what Bolt uses to save and load data) is in part the culprit here. It's the most powerful serializer available out there, but it's also one of the slower ones. I might have to introduce another storage format that's faster just for the unit database, for example SQLite, but that's another layer of complexity and dependencies that I'd like to avoid if I could.

Well, I think with how cool Bolt is already, you'll come up with something great! 

Playing arround with bolt for one day now but i have to say i am not really happy with it.
On my i7, 16RAM it takes sometimes more than 10 seconds before i can type to search an function.

I tied it on my old notebook and it needs quite the same time. This is not really usable for my daily work. The Opportunity from Node based scripting systems should be to get a prototype very fast done.


Okay after playing a little bit arround it was time for buisness, so i imported bolt into a medium sized project.

Loading times, when pressing play in the Editor is about one minute and when exiting the play mode it takes arround 20 seconds, before i can work on my scene.

Not really suitable to work with.

Could it be possible, to add an option to switch the codebase analysis on or off?
So you could switch it on, when working active with bolt and switch it off when working in the scene?


Hey JPAC!  Unity itself reloads everything when you recompile, which in turn forces Bolt to reload everything, and since Bolt is mostly generated from both Unity code and your own, it has lots of stuff to dig through.

Its currently on the bug tracker and the lead dev, Lazlo, is working on a solution to speed things up :)

This could help some what if you have loads of assets in your project.

I haven't tried it yet as Buying bolt was enough money to spend for this month. The good news is that the month is nearly over.


Good find. Useful no matter what. I'm just shocked I haven't run across it before. Ha.

Hey NeedsLoomis,

It would be great if you could make that a manual process.  So, while I'm working on unrelated code, nothing in Bolt updates/recompiles.  I'm not sure if that's possible, but that would be really good, I'm not liking this extra time... thankfully I can still use unity during that time, but if I make a code change + play, it does seem to take a bit longer than I normally expect which is getting annoying :(


Hey JPAC, take a look here if you have not, http://support.ludiq.io/topics/309-remove-loading-times/, The Dev Lazlo is aware of the issue and is thinking of ways to improve it.

Thanks, did not see that thread!

Any updates on this?  Any way to speed this process up or suspend it until we need it?

JPAC, take a look. http://support.ludiq.io/topics/318-taking-a-short-break/. He is checking the forums while away but will be back soon.

This is really important that it be addressed asap, we have a major production coming up and if these issues don't get fixed, we'll have to decide on Playmaker for the project. AOT and IL2CPP being the other major and crucial factors as we will be targeting mobile.

The additional compilation time that occurs every time the editor recompiles is noticeable enough to where it's a problem as it increases our iteration time. Even if it's just 5 extra seconds, we will have over 10 people working on this project, this could very easily translate to hours of lost productivity for the team.

Someone posted about this before, https://www.assetstore.unity3d.com/en/#!/content/59029

Could very well help with the issue for now. While it may not be the ultimate solution it is certainly worth it for 10 bucks for general use.


I just picked up PackageMaster. I will post when I test it and let you all know if it helps. The link is in my post above.

Ok, just to update on this for those interested. While the Loading issues have disappeared, I also wanted this asset for the additional benefits.  Sadly, it is not compatible with changes Unity made for compatibility with macOS Sierra and the dev has hit a roadblock figuring a fix rendering the asset useless to me as I program and develop on Mac's.  

@William ianneci

Did you had some success with PackageMaster? 


Sadly it will not even run at the moment and the Dev has been unresponsive. I will update here when/if it gets resolved. Even if it is not useful for Bolt, thought it should be to some extent, it will be useful for many other reasons.

On a good note, if you all are not following Bolt/Ludiq on Twitter, he just tweeted he has found what will probably be the solution for now, very promising.

Surprised he has not posted here yet but am sure he will when he is ready.


I don't think a third party asset would be of any help to speed up the loading time, I don't recommend investing in one if that's your only objective.

As William mentioned though I did make some significant progress on the loading times. I'm not done yet but I should be this week. I'll make an announcement once I'm done!


Big news on this!

I'm done with the core optimizations I wanted to make. It's not perfect, but it's a lot better.

In summary:

  • Unit options loading is now ~12x faster (was 12s on my machine, now 1s)
  • Plugin initialization is now ~3x faster (was 3s on my machine, now 1s)

Note that unit options loading still happens on a parallel thread, so it shouldn't block your game if you have multiple cores (although it may reduce your framerate a bit until it's done).

Plugin initialization is what caused the "playmode hang". Unfortunately I haven't been able to eliminate it completely, because Bolt is an enormous plugin that must pre-load things in the first frame for the editor to run smoothly. However, now that it's much faster, switching to play mode should be a lot smoother.

All of this required a big refactoring, so I still have some testing and polishing to do before I push v.1.0.4 to the asset store. I expect to submit tomorrow, so you can expect the update early next week. I'll also update the documentation on how to generate & update the new unit database.

Thanks everyone for your patience on this!

12x faster loading 😁

Man you are awesome 👍

Can't wait to get the update 

Great job! I, as well, cannot wait for the update and to start using Bolt for real in my current project :)

Excellent!!   I've had to stop working with it, but I cannot wait to try this out.  It was perfect for my needs besides this issue.  Can't wait!  Thanks for the work!

I only made a simple rotating cube and the playmode is hanging for a good 7 seconds... this is a huge lag compared to without Bolt...

That’s not normal. What are the specs of your computer? Are you using the latest version?

I’ll probably look into optimizing the plugin initialization even further down the line, but it should be much faster than 7s already (about 1-2s).

Windows 10 Home 64-bit

Intel(R) Core(TM) i7-6700 CPU @ 3.40GHz (8 CPUs), ~3.4GHz

NVIDIA GeForce GTX 970


Unity 2017.1.1f1 and should be the latest version of Bolt (unless you updated it within the past few hours)

Odd, I have nearly identical specs on my development machine and load times are 1s hang + 1s threaded. Do you use a SSD or a HDD?

I've tried with Unity and the project both on SSD and HDD. Very little difference.

It seems to be hanging at Documentation(UnityEngine) most of the time.

I, too, am also having this issue. Very beefy machine; get hangups on every playtest upwards to 15 seconds. SSD or HDD, no matter.

Simple rotating cube, there is a considerable hang; after pressing play, which is about 7 seconds, and then the graph and all related elements (variables, inspector) go in loading for another 7 seconds until the cube actually starts rotating. 

Thought you'd like to know! Otherwise, this is a super good tool and can't wait to check this bad boy out again after a few more months under its belt. 

That's not normal, and definitely worrisome to me. Can you please:

  • Post your specs
  • Post a screenshot of the profiler with Deep Profiling + Record Editor enabled, on the 7s peak when you enter play mode

This would help me find the cause of the issue. I do not experience this lag anymore since 1.0.4 at all on my machine, but apparently you and at least one other user does.

I do too. I think I break the record. Try sometimes over a minute waiting time. Minimum, about 30 seconds.

I'm on a brand new Laptop, MSI 16 GB Ram, i7, GTX 1060. I use an external HDD, but I do have an internal SSD. Shouldn't have an issue. The list was sooo long, so I took 4 photos instead of one. Hope this helps. I'll keep it open if you need more data soon.

*Edit: a little more spec details

Yup! My specs are as follows:

  • Mac Pro (2012), OS on SSD, Unity Project on HDD. (Copied project to test on SSD and same problem). 2x 2.4GHz 6-Core Intel Xeon. 64GB RAM. GTX 780 Ti.

I did extra and recorded the hangup. It actually took considerably longer with the profiler up and the selected object's graph on display. Profiler hung too, which is why I recorded:


That seems related to graph instantiation. If so, the next update should help a lot. Let's take another look at it after the update to make sure, alright?

Will do and will update you once it goes live!

Wow, I just had the time to look at your video and that is definitely not normal. I opened a new thread to discuss and profile the issue, please post your data if you can now that 1.1.2 has been released:


That is odd.  My primary system is a 2011 IMac. All factory hardware and certainly not cutting  edge. After 1.0.4. all speed and loading issues dropped to nothing with only an occasional slowdown.

Thing is, I remember my speed going up, as I was praising Lazlo for the good work on that. Sometime in there, it stopped being as friendly. I've been refraining from testing often as it's a lot of waiting. All I remember doing is creating a keyboard prefab. Each key has a effects loop with events to call them when on the button. That seems to be when I really noticed it starting to get worse. But I don't even instantiate on awake or start. I do it manually at a loading screen. Shouldn't effect start up I'd think.

I only made a  empty obj  and the playmode is hanging for a good 7 seconds... 

this is a huge lag compared to without Bolt...


me too

its so slowly when I want testgame  

and the graph will be lags by use more………………

Since this topic was about another type of loading times, I created a new one to discuss playmode hang, with instructions to help me fix it. Please continue all conversation here: