Garry's Mod

Garry's Mod

NPC Spawn Platforms v3
 This topic has been pinned, so it's probably important
brentonimo 16 Jul, 2019 @ 9:20am
How to change the NPC_Classname to a Custom NPC
I'm hoping you can help me with this, I've added the FGD to Hammer, specifically garrysmod.fgd.

The entity arrives perfectly inside of Hammer, I'm unaware however as to how to change the NPC Class within Hammer to something like, let's say, ODSTs with ARs.

Hopefully you can educate me,

Keep up the tremendous work.
< >
Showing 1-4 of 4 comments
brentonimo 16 Jul, 2019 @ 9:21am 
PS: Your cursed
https://imgur.com/YOXYAo4
brentonimo 17 Jul, 2019 @ 12:58pm 
For anyone interested, I have figured out how to include Workshop NPCs and how to signal to Hammer on how to pull reference them.

You'll want to unpack your NPC addon of choice with gmad.exe found in the Garrysmod Bin Folder.

When the respective addon's folder is generated in your garrysmod/addons folder, open the lua folder and find the script for your NPC of choice.

In there you'll be looking for a class name similar to the Default NPC classes seen in Hammer such as "npc_soldiercombines" or "npc_citizen".

In my case, it was "npc_alfie_odst_friendly".

Copy that classname and paste in the NPC Classname section of your NPC Spawnplatform properties.

Save and Compile your map and load in Garry's Mod and VOILA!

Hope this helps anyone who wants to build these into their map and not be limited to HL2 NPCs.

I'll post more as more becomes revealed through trial and error, such as a custom weapon class and some ability to modify bodygroups.

Stay posted.
brentonimo 17 Jul, 2019 @ 1:05pm 
Ok same deal with weapons guys and gals:

Unpack the NPC Swep addon of your choice and head to the lua for the weapon classes.

There you'll find a list of all the various weapons that addon references and, same drill, copy and paste into the Weapon Class section of your Spawn Platform properties menu within Hammer.

Save, Compile and Load the map and once again, works like a charm.

In case it isn't already clear, make sure to actually have the addon installed in your addons folder and make sure your referencing NPC SWEPS not player weapons or props!

Good luck!

If I can come up with a work around for Bodygroups you'll find it below in time.
Lexi  [developer] 18 Jul, 2019 @ 8:40am 
I'm glad this is working for you, this feature has always been somewhat experimental. I don't currently have any way to set body groups (or spawn flags). Happy to help with other problems
< >
Showing 1-4 of 4 comments
Per page: 1530 50