In-depth guide to creating my own gamemode.

Videos aren’t that great and the tutorials I see are all for deathmatch games or too simple ones. I can code the smallest,decent amount of lua, but I have no experience in making my own gamemode. I downloaded the skeleton gamemode and the only thing I could get to work in game was the HUD health.

I’m trying to code a gamemode that has roleplay elements, but I’m not really asking how to make a roleplay gamemode, just something I can play with my friends and has simple prefabs. Can someone help me here?

Gmod wiki + humblesnurp

His tutorials are really good, but half the time I can’t tell whether I’m supposed to tab or space, as I have learned different things require different kind of space. As for the wiki, could you direct me to specific pages for gamemode coding? Or is there just that one lua section for creating a basic gamemode?

1st. You need the skeleton http://www.garrysmod.org/downloads/?a=view&id=39584
2nd. I’d suggest this tutorial http://wiki.garrysmod.com/?title=Simple_Gamemode but look at other parts on gmod wiki they will help you http://wiki.garrysmod.com/?title=Lua_Tutorial_Series.

Finally. Look at other gamemodes or addons like darkrp and see if you could use their codes.

Don’t try rushing in to try and make a gamemode, you won’t finish it and you’ll throw it out.

Look at the hooks/functions garry has provided and just play with them and eventually you’ll get better and better.