0
Answered

Cache needed for this?

Rakka Rage 3 years ago updated by Lazlo Bonin (Lead Developer) 3 years ago 1

does anyone know if anything is cached automatically? the editor shoes some calculable values it knows these dont change am i wasting my time caching those?

it could and should cache those automatically right?

or idk thanks

Bolt Version:
Unity Version:
Platform(s):
Scripting Backend:
.NET Version (API Compatibility Level):
GOOD, I'M SATISFIED
Satisfaction mark by Rakka Rage 3 years ago
+2
Answered

Hi Rakka,

Yes, cache is needed for this if you want to avoid multiplying the value each time the output is fetched (however, for such a small operation, it would likely be premature optimization).

The Bolt predictive debugger is smart enough to know these are predictable, but the runtime doesn't cache any value behind your back to keep the graph's understanding clear and predictable.