Just Wondering

Is there anyway to reload the lua files while in game so u dont have to exit gmod and come back?

also, when i save the Lua file and re enter gmod, it reverts back to the original file before i saved it

I just use the ‘reload’ command in game.

Or if I am testing multiplayer, I just create a new server from the main menu.

All the changes appear instantly for me.

Refreshing the map works for me

It depends on the lua file.

If it’s a script in the /lua/autorun, you can use:
lua_openscript_cl <file>
lua_openscript <file>

If it’s a script in the /lua/entities or /lua/weapon you can use lua_reloadent (needs download; get here:)

I’m guessing the reason it was reverting back is because there was an error in the script so it wouldn’t run. If you use lua_openscript then it’ll tell you the error when you try and open it.

Well ive been trying lua_openscript(“Test1.lua”) and its not working

lua_openscript_cl autorun/client/lulz.lua