girvel / fallen

Tactical adventure made with LOVE2D
Other
2 stars 0 forks source link

Tactically mark statics? #385

Open girvel opened 2 months ago

girvel commented 2 months ago

Right now, statics are used to prevent save loading issues. For 2.0+ maybe there is a point in marking everything static with "static" to (1) for sure minimize save files size and (2) maybe allow loading saves from different patches.

girvel commented 2 weeks ago

Maybe we shouldn't even mark statics explicitly; maybe we can just infer that something is static; we can't use newindex for this, because newindex + nested tables inside the modules with possible custom types = implicity nightmare; but maybe we can mark them after modules are initialized or required, because we expect no mutable state to be stored in non-global modules?