• Binary Module Repository
    22 replies, posted
[B]BINARY MODULES FOR GMOD[/B] I was wondering if anyone has ever bothered to make a big, comprehensive collection of binary modules for GMod? Right now it's a real pain to find binary modules. There are a few that are fairly well known and recognized, and those are pretty easy to find (MySQL, Sockets, and other general application modules), but then there are those with narrow or extremely niche uses, and some are just broken/outdated (but still have source code available). If anyone's feeling up for it, we could possibly make some sort of public repository with mirrors of modules, and, possibly with source code. Throw in your own modules if you have any, and ones that you simply know of. Maybe with collective effort we could build a big and comprehensive repository of modules for GMod. [sp]unless I'm really dumb and just don't know of an existing one[/sp] [B]EDIT:[/B] Links where you can find various modules: [url]http://christopherthorne.googlecode.com/svn/trunk/[/url] [url]http://blackawps-glua-modules.googlecode.com/svn/trunk/[/url] [url]http://gmodmodules.googlecode.com/svn/trunk/[/url] [url]https://github.com/glua?tab=repositories[/url] [url]https://maurits.tv/data/garrysmod/lua/modules/[/url] [url]http://mattmodules.googlecode.com/svn/trunk[/url] [url]http://gbps.googlecode.com/svn/trunk[/url] [url]http://spacetechmodules.googlecode.com/svn/trunk[/url] [url]http://gmod-haza.googlecode.com/svn/trunk[/url] [url]https://bitbucket.org/breakpointservers/bkacjios-glua-modules/src[/url] [url]https://github.com/Sapd/gm_performance[/url] svn://svn.metastruct.org/gbins [url]http://bitbucket.org/danielga/[/url] [url]https://github.com/ExtReMLapin/TrackIR_GMod[/url] Once I have some spare time, I will go through all these links and compile a repository of modules, and then we'll see what happens next.
[QUOTE=Handsome Matt;48693879][url]https://github.com/glua?tab=repositories[/url] There's quite a few here. If people making binary modules put them on here they'll have access to build servers for every platform.[/QUOTE] That's really nice, though there aren't that many modules on there. I'm proposing a public repository for people to dump all kinds of modules there, legacy or new, working or not. Even a broken module may prove as useful learning material for other users.
[QUOTE=typedef state;48693902]That's really nice, though there aren't that many modules on there. I'm proposing a public repository for people to dump all kinds of modules there, legacy or new, working or not. Even a broken module may prove as useful learning material for other users.[/QUOTE] The glua organisation is going to be sticking to working modules that implement the modle-base repository. The reason for this is that it abstracts away common issues: using valves tier1 with the wrong runtime, dependencies (Garry's interface/source SDK) and compilation (there's neat automation). But it isn't done yet. [url]https://github.com/glua/module-base[/url] [url]https://github.com/glua/module-base/wiki[/url] To hell with all these difficult to compile things. You can have [url]https://github.com/glua/modules[/url] and [url]http://bin.glua.io/[/url] or something like that, though.
There's also [url]https://maurits.tv/data/garrysmod/lua/modules/[/url]
[QUOTE=Willox;48693973]snip[/QUOTE] Yes, I understand. What I meant was more like a separate repository for -all- modules that exist, for the reasons that I outlined in my previous post. EDIT: The last two links you provided don't seem to work.
[QUOTE=typedef state;48694235]Yes, I understand. What I meant was more like a separate repository for -all- modules that exist, for the reasons that I outlined in my previous post. EDIT: The last two links you provided don't seem to work.[/QUOTE] I'm offering to give you both (or similar) links.
[QUOTE=Willox;48694266]I'm offering to give you both (or similar) links.[/QUOTE] Oh. Right. I misinterpreted your post, sorry. I think it would be great. Even broken modules can be useful for legacy and education purposes. I'll try and compile a list of as many modules as I can, and then we can work something out.
Here's an example on how to do binary modules in C# [url]https://github.com/cartman300/gmsv_gsharp_win32[/url] The lua API is a bit rusty but it can be easily modified to include this, it's just a matter of changing the lua dll name anyway (and it's just a single source file so it can be easily included) [url]https://github.com/cartman300/Lua.NET[/url]
Maybe you can find a use for that: [url]https://github.com/Grocel/GMod_Modules[/url] Also (ignore already named ones please): svn://svn.metastruct.org/gbins/ [url]http://blackawps-glua-modules.googlecode.com/svn/trunk[/url] [url]http://mattmodules.googlecode.com/svn/trunk[/url] [url]http://gbps.googlecode.com/svn/trunk[/url] [url]http://christopherthorne.googlecode.com/svn/trunk[/url] [url]http://spacetechmodules.googlecode.com/svn/trunk[/url] [url]http://gmod-haza.googlecode.com/svn/trunk[/url] [url]http://gmodmodules.googlecode.com/svn/trunk[/url]
There used to be a sub-forum on facepunch for binary modules, but it was removed. Here's my module. [url=https://facepunch.com/showthread.php?t=1005357]gm_debugger[/url] I should probably put it in a repository or something.
Looks like you guys already found mine.
I moved my stuff to bitbucket awhile ago seeing how google code was going to get shutdown at some point. I thought I deleted it and made it redirect, but apparently the repo is still technically there.. Fucking google code.. [url]https://bitbucket.org/breakpointservers/bkacjios-glua-modules/src[/url]
[QUOTE=typedef state;48693902]That's really nice, though there aren't that many modules on there. I'm proposing a public repository for people to dump all kinds of modules there, legacy or new, working or not. Even a broken module may prove as useful learning material for other users.[/QUOTE] Here is mine: Github: [url]https://github.com/Sapd/gm_performance[/url]. See "releases" for binaries. Count's FPS by a system timer, and can measure performance and provide excel /libreoffice calc output of it. See readme for an example. You can get the FPS etc. via lua functions. Useful if you want take measures if it's too low, or if you just want to inform admins of lagg.
[URL="svn://svn.metastruct.org/gbins"]svn://svn.metastruct.org/gbins[/URL] random binaries and build env used on some metastruct modules. [url]http://bitbucket.org/danielga/[/url] has ported many modules to his compiling system over at bitbucket as you can see.
[url]https://github.com/ExtReMLapin/TrackIR_GMod[/url] TrackIR API Almost off-topic :[URL="https://facepunch.com/showthread.php?t=1077009"] Do we have a working unrequire module ?[/URL]
[QUOTE=ExtReMLapin;48702364]Almost off-topic :[URL="https://facepunch.com/showthread.php?t=1077009"] Do we have a working unrequire module ?[/URL][/QUOTE] Why do you need a module for that? [code] function unrequire(mod) local _R = debug.getregistry() local modMeta = _R["_LOADLIB"] for key, ud in pairs(_R) do if type(key) == "string" and key:find("^LOADLIB: .+gm%w%w_" .. mod .. "_%w+%.dll$") and type(ud) == "_LOADLIB" and getmetatable(ud) == modMeta then print("Unloading module: " .. mod) _R[key], _MODULES[mod] = nil, nil modMeta.__gc(ud) end end end [/code] Note: not all modules can be unrequired easily, some may cause the game to crash.
Thanks everyone for your input so far, it is greatly appreciated. Hopefully we will be able to make searching for gmod binary modules easier. :v:
[QUOTE=mijyuoon;48702882]Why do you need a module for that? [code] function unrequire(mod) local _R = debug.getregistry() local modMeta = _R["_LOADLIB"] for key, ud in pairs(_R) do if type(key) == "string" and key:find("^LOADLIB: .+gm%w%w_" .. mod .. "_%w+%.dll$") and type(ud) == "_LOADLIB" and getmetatable(ud) == modMeta then print("Unloading module: " .. mod) _R[key], _MODULES[mod] = nil, nil modMeta.__gc(ud) end end end [/code] Note: not all modules can be unrequired easily, some may cause the game to crash.[/QUOTE] Well, it's not calling [URL="https://github.com/garrynewman/gmod-module-base/blob/master/example/src/gm_example.cpp#L51"]GMOD_MODULE_CLOSE[/URL]
[QUOTE=ExtReMLapin;48710148]Well, it's not calling [URL="https://github.com/garrynewman/gmod-module-base/blob/master/example/src/gm_example.cpp#L51"]GMOD_MODULE_CLOSE[/URL][/QUOTE] When the __gc method gets called it should call the modules gmod13_close. Try my version of unrequire? [url]https://gist.github.com/mcd1992/845260a922fb6e9abe73[/url]
[QUOTE=ExtReMLapin;48710148]Well, it's not calling [URL="https://github.com/garrynewman/gmod-module-base/blob/master/example/src/gm_example.cpp#L51"]GMOD_MODULE_CLOSE[/URL][/QUOTE] That sounds like a bug in GMod itself.
[QUOTE=ExtReMLapin;48710148]Well, it's not calling [URL="https://github.com/garrynewman/gmod-module-base/blob/master/example/src/gm_example.cpp#L51"]GMOD_MODULE_CLOSE[/URL][/QUOTE] Well, it called gmod13_close() last time I checked (a few weeks ago). [QUOTE=mcd1992;48710672]When the __gc method gets called it should call the modules gmod13_close. Try my version of unrequire? [url]https://gist.github.com/mcd1992/845260a922fb6e9abe73[/url][/QUOTE] I think the code I posted is basically yours (with some tiny changes I made). I found it on Facepunch long time ago.
Calling __gc like that looks dodgy as hell. Have you considered removing the result from _MODULES, iterating the numeric indexes in debug.getresgitry() and replacing matching records with new tables and then calling collectgarbage()?
Sorry, you need to Log In to post a reply to this thread.