Out of game lua tester

I don’t know if there is one (If there is please link)

The Request

I would love to have a out of game lua tester. Basically it would run your program out of GMOD and if it runs fine with no problems (Code wise, i.e no Lua:Line99 insert error here) it would tell you that your code is good. Of course if it does not work out very well it will return faulty and explain the specific problem (I.e Lua:Line55 insert error here)

If anyone could make this or find it. Would be much obliged.

Thanks, and please.

There is such a thing that comes with the lua distribution, it’s called Scite. It works perfectly but you can’t use any Garry’s Mod specific syntax or libraries in it, and obviously can’t emulate entities interacting. All of that is unique to Garry’s Mod and there is no way around it. Is there a reason you want to test outside of Garry’s Mod? If it’s to make it faster then you’re probably doing it wrong. :smile:

Well what I am using is dermas which needs to go into autorun, and from research you need to restart GMOD each time, and with simple errors like missing a end or something, it just takes to much time. Can you link me to the page?

Well first of all restarting the map is all you need to do to completely clear the lua states. Then there are many console commands you can use to quickly test your code. Some of them are lua_openscript, lua_openscript_cl, gamemode_reload, gamemode_reload_cl. You should also be coding with Garry’s Mod in windowed mode so you can quickly switch to notepad++.

I guess. Thanks.
( i am extazy)

World of warcraft used to have something like this, so I’m sure that it can be done :slight_smile:

Put it in your lua folder and type in your console lua_openscript_cl filename.lua it’s the fastest way I think.

You can also use lua_reloadents when the map is empty to reload all scripted entities. Not that it matters, but still

Yes it cant be done but its pointless