Garry's Mod

Garry's Mod

JMod: Half-Life 2
 This topic has been pinned, so it's probably important
Rikou 17 Oct, 2023 @ 7:12pm
How to add JMod HL2 items to crafting (the lazy way)
So, I decided to make a crafting config for this mod a couple days ago, and decided I should release it to the public, with a lil guide on how to implement it :3

WARNING: This contains JSON, a very stubborn programming language.

1 | Get everything you'll need
First, you'll need the crafting config: https://pastebin.com/NyMH1CDk
You can edit as you please, I just put the crafting ingredients I thought were reasonable. Editing may be difficult, since it is in JSON format. Use a parser or linter if you need to.

You'll also need to navigate to your JMod config file. It should be located at:steamapps/common/GarrysMod/garrysmod/data/jmod_config.txt

Keep in mind, You will not need to restart Garry's mod, or even reload, to implement these changes. This is best done while you're still in a game.

2 | Do the meticulous stuff
This is where the JSON begins. If you mess anything up, the crafting recipes may not work.

You'll first copy the config values off of the Pastebin, and be sure you've copied them completely. Then, in your config file, look for the commaless bracket that ends off the Craftables. It should be here (should be on line 1770 of the config, if you're using a code-oriented text editor):

"description": "Will provide light damage protection at little cost to mobility." } }, "General": {

You're gonna wanna do a bit of a weird maneuver; Add a comma to this bracket, hit enter, and then paste on the new line from the pastebin. The pastebin has a bracket that will automatically close the value "Craftables".

Don't forget to save the file! this can be done quickly with Ctrl+S.

3 | Finalize your changes
Once your config file is saved, along with all the changes you've made, execute jmod_reloadconfig in the developer console. Then, check both of the crafting menus affected; Workbench and Toolbox.

If they're not there, you can execute console command jmod_resetconfig and try again, or use JSONLint[jsonlint.com] to troubleshoot.

If they are there, happy crafting~! :luv:
Last edited by Rikou; 20 Dec, 2023 @ 9:29pm
< >
Showing 1-8 of 8 comments
arsonist (Banned) 30 Oct, 2023 @ 12:56pm 
yo tysm
Thanks for the guide, helped me understand on why my seemingly fine custom crafting recipes didn't work properly.
AdventureBoots  [developer] 10 Nov, 2023 @ 7:54pm 
Nice to see someone do this, not quite how I'd price everything, but it's good non-the-less
TankDestroyer 28 Jan, 2024 @ 7:05pm 
please can you make ready config for download?
or video guide?
GameWorldReality 15 May, 2024 @ 10:43pm 
i dont know anything about coding so i cant really use this.. here's to pray JMOD:HL2 will get an update that adds them to vanilla jmod crafting :pray:
I pasted the config as I should, reloaded the jmod config in the console, but still I can't find most of your addon stuff, what can I do about it?
AdventureBoots  [developer] 7 Jan @ 11:09pm 
There is now a concommand for merging pre-made recipes using lua.
`jmod_hl2_merge_recipes`
Here is the best, I used it and thought it didn't work and then I decided to reload the krafts config, and oh wonder! All the crafts from the mod showed up! Thanks again
< >
Showing 1-8 of 8 comments
Per page: 1530 50