Newbie - Learning Lua; in depth

I’m wondering if there’s any guides to specifically script for Garrys Mod, for making weapons and stuff and ext.
(In idiot terms, if possible. pl0x.)

I’ve opened up a script or two, and was confused by some of the codes, as most guides don’t tell you what how to make little bars or anything.


Bunch of nifty tutorials to get you started.

  1. its called the SEARCH FUNCTION!!! theres a lot of these how do i learn lua threads
  2. that is Lua in its flavorless form not for gmod but the basics read it love it learn it.
  3. thats the gmod wiki with allt he specific syntax of gmod
  4. Next time please use the search function
  5. Open up simple scripts and try fiddling with the values see what happens.

I am still pretty new to lua, but I understand most basic coding.

What I did was I used the tutorials on and learned how lua is structured and how it works. Then I opened up some simple scripts so I could see how they worked. Afterwards I started editing them to make them more useful to me. Finally I started to create my own :slight_smile:

My first real script was an SWEP, and these tutorials helped me a lot:
How to make SWEPs V2
How to make SWEPs V2

V3 teaches you about hexing, tools and NPCs too!

I hope these help, and good luck with learning lua.