I think a super nice feature for editor 2 would be to make any new function you add, automatically local, just spent a day, wondering why my functions weren’t being called, only to realise I’d forgotten to make them local.
Or better yet a step debugger would be nice, I so miss that.
How would that work? Do you mean some kind of pre-processing of the Lua code before running it or that the editor somehow adds a local keyword before the function declaration while I’m writing it?
Na I don’t think I was being too serious, perhaps a post it note on the screen saying all functions would be better local, I was just so annoyed with myself for missing it.
Well, what we could do, and probably will as we improve the Lua editor features is to incorporate a proper linter that would warn when you’re trying to access a global variable (just like the linter in Atom and Sublime, both of which are based on LuaCheck if I’m not mistaken).