Shared state question (SOLVED)

Hey everyone,

is there any particular reason why the Shared State config property is off by default?
Without that lua modules don’t behave like singletons.
Are you trying to suggest a different pattern? How would you then share a table that can be queried/modified by various parts of the game then?

Thanks :slight_smile:

2 Likes

It was the default from a long time ago, and since we didn’t want to break backwards compatibility for existing projects, it was left as “off” by default.

For new projects though, we use templates with good known values, and in this case, we set this property to be true.

Is this not the case for you?

3 Likes

I think it’s legacy from an old project, but my question sparked from reading in the manual that is off by default.

Thanks!

3 Likes