Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How do I load a library into a global variable and use it in Studio dev console?

Asked by
VilgO 0
6 years ago
Edited 6 years ago

I want to use inspect.lua to examine the game state at runtime. How do I load it with a script so that it's always available in the console, and I don't have to write inspect = game.ReplicatedStorage["inspect.lua"] every time I want to use it?

Assigning to _G.inspect or shared.inspect surprisingly doesn't work, the variable is nil.

Using setfenv(0, ...) doesn't work either.

Answer this question