i have a script with a bunch of structs in ( my game data script ) and i wanna be able to change values in it & for it to update. putting any of the live call functions in the script gives me an error .
Code and asset live-reloading for GameMaker! · By
Depends on what’s in the script!
If it’s just struct assignments that are done once on game start, you’d want to wrap them in a
function some_init() {
global.a = { ... };
...
}
some_init();
because global script init is a little quirky to resolve from GML.
Then you can use live_code_updated to re-run the (updated) script when a new version is loaded.