Title / Thread Starter Last Post ByReverse Sort Order Replies Views
Garry

MODDING HELP - READ ME FIRST - LAST UPDATED 5 OCTOBER 2015

This forum is for help modding Garry's Mod. This does NOT include Mapping or Modelling. Mapping: http://facepunch.com/forums/40 Modelling: http://facepunch.com/forums/38 Your first port of call should be the Garry's Mod Wiki. If you don't find...

garry Lua King x 27
27th February 2013
by garry Go to last post
0 17,018
Link

NEED A CODER? DON'T MAKE A THREAD - LAST UPDATED 25 OCTOBER 2013 - READ THIS

We are not interested in threads that state you are looking for a coder for your server/addon/gamemode. Please instead use these resources: https://scriptfodder.com/ Want to learn to code? http://facepunch.com/showthread.php?t=1250283

garry Winner x 38
3rd September 2014
by NiandraLades Go to last post
2 16,615
Request

Ammo supply crates

I've been wanting to get an Ammo supply crate like the ones from the Half Life 2 campaign... I always liked the green crates/trunks full of ammo. I couldn't find what I'm looking for, but I could have been wrong on how I worded my searches. I was...

10th July 2009
by Entoros Go to last post
1 734
Help

Canceling a timer

Is there a way to cancel a timer once it has been created? I have a timer set on a Ply.KeyDown, and I want it to cancel on my Ply.KeyUp Also as a side note, are you able to set a +(func) button as a keydown/up, eg. +use, or +walk

10th July 2009
by Mandalore777 Go to last post
7 641
Request

A stash system for hunting.

This would be good for an half-life 2 map in gmod. Disable noclip and you're on your way. This is my layout that I did in an old game. lmd_stashzone ***(L) A zone to define an area for stashes. Also controls how many stashes can be spawned per...

10th July 2009
by Unreliable Go to last post
0 462
Request

Module to supress engine erorrs.

PLEASE can someone make a module to suppress those fucking red engine errors! It's REALLY annoying to go into developer mode to work on something using the overlays and without having to keep hitting ` and then you get flooded with a fuckton of pointless...

10th July 2009
by Lexic Go to last post
0 453
Help

unresolved external symbol

When I try to compile a GMod module I get (only) this error. error LNK2001: unresolved external symbol "void * (__cdecl*__cdecl Sys_GetFactory(char const *))(char const *,int *)" (?Sys_GetFactory@@YAP6APAXPBDPAH@Z0@Z) Any ideas why? Thanks.

10th July 2009
by Skondra Go to last post
8 1,157
Lua

Derma problem.

includes\util.lua:127: attempt to index local 'self' (a number value) And the script: local PANEL = {} AccessorFunc( PANEL, "RectColor", "RectColor" ) AccessorFunc( PANEL, "BoxColor", "BoxColor" ) AccessorFunc( PANEL,...

10th July 2009
by conman420 Go to last post
2 711
Help

Sweps Dissaper After Editing

Whenever I make or edit a Swep, it no longer shows up in game, the latest was when I added a function Swep:Think, It no longer shows up in game and I can't get it in console, the same thing happens if I make one using Swep Makers, even if I put them in...

10th July 2009
by cercerd Go to last post
2 555
Help

Where are gmod's chair / vehicle lua files

My banned friend wants me to ask dumb questions for him. Answer this one

10th July 2009
by Lexic Go to last post
2 1,701
Lua

String library extensions

I've recently been working on several small and large projects that were using a lot of operations with strings. Somewhere in the middle I found that I was using the same code over and over again, and that the standard functions supplied with lua and the...

10th July 2009
by ChewGum Go to last post
2 1,038
Help

Scripted NPCs Dying

i'm trying to make a scripted NPC and when it dies it should turn into a ragdoll and fall to the ground i pulled this from the wiki function ENT:OnTakeDamage(dmg) self:SetHealth(self:Health() - dmg:GetDamage()) if self:Health() <= 0 then //run...

10th July 2009
by enjia2000 Go to last post
0 444
Help

Interacting with html panel contents

It's me... again :) I have html panel with some things which controlled via javascript, is there any way to interact with it's contents? I tried openurl with something like javascript:blablabla but it doesn't work.

10th July 2009
by Megalan Go to last post
2 587
Help

Problem with saving derma cords

Hello i am making a basic game mode with a friend. What i am currently tying to do is save the coordinates of a derma frame on the client. this is what i have so far. function save() file.Write("Basemod/saves/data.txt", frame:GetPos()) end ...

10th July 2009
by meka/sniper Go to last post
2 477
Help

Qmenu again

Anyone care to help me, I am making a gamemode but I want the normal qmenu only I want to insert only models that I specify and Tools I specify. The gamemode is derived from base I read some stuff and found this : concommand.Add( "+menu",...

10th July 2009
by quincy18 Go to last post
2 723
Lua

Effects list

Anyone got a nice list of all the effects to use in our LUA coding? Like ""HelicopterMegaBomb"" and so on. (Ps. if anyone know a nice smoke effect, please post it)

10th July 2009
by Yobdren Go to last post
5 2,481
Question

breakable doors?

like L4d. but not from l4d. is it possible?

10th July 2009
by kevkev Go to last post
4 770
Request

[REQ] Particle Maker v2.x update?

There's this awesome Tool called the Particle Maker, it's current probable final version is v2.0. But there are some annoying bugs in it, can somebody fix it please? or can the real developer of that addon please fix it? I got screwed up after the...

10th July 2009
by Shadow909 Go to last post
0 377
Question

Lua and Dll

I was wondering, how hard/time consuming would it be to link two separate servers so that people may join and have their items on one server, and on the other server.

10th July 2009
by Noobulater Go to last post
2 581
Help

Slow Walk speed/run speed and Realistic Falling Damage.

Alright, I've recently compiled a lot of mods for Garry's mod that I've collect over about the past year. I've found my favorite ones and blah blah blah. What i did though is 7-Zip'd them all into one folder, all 6.52 GB's then installed them all into...

10th July 2009
by X e r o Go to last post
4 3,178
Request

[REQ] HL2 Ep1 The Core as AR2's Charged Bolt in MP

Wow, I don't know how I came up with it but... Could someone mod the AR2 to make it shoot out the Core (Dematerializing Sphere) from Episode one, as the right mouse click weapon fire feature. And don't let it fly exactly just like the original AR2 bolt...

10th July 2009
by Shadow909 Go to last post
0 755
Question

MY code won't work, but it's much shorter...

(i AM attempting to make a SWEP) If you could just tel me of it's missing something, that's be great. if you actually FIX it, i will be happy beyond belief, and i guess I'll give you credits in the information and stuff... 10:12PM if (...

10th July 2009
by Marine123 Go to last post
38 1,789
Lua

Rewind Tool

can some one make a tool based off of the rewinding time from the time grenade?

10th July 2009
by jadestone Go to last post
0 445
Request

Stone Gargoyle Swep

Using the fast Zombie Swep, add these peramiters. Make the Fast Zombie 2x as weak as the Classic Zombie, and just as slow. Primary: Zombie kneels down, puts its head down, and covers itself with it's arms (use scripted animations from other npcs)....

11th July 2009
by Obi-Trev Go to last post
0 344
Question

Where to learn to make npc seller by using lua?

Is there anywhere that I can find a tutorial about making npc seller? Like, a players able buy something from npc seller, I saw some of them on some server, so I thought I would make myself for my server. Thank you if your helping, and if you saying...

11th July 2009
by Unrealomega Go to last post
3 972
Question

Dynamic DOF

Is there somone that already made or someone that can make a dynamic Depth of Field so that what ever you are looking at with your crosshair is focused but everything else is blurred within a tolerance (10ft + or - what you are looking at is un blurred or...

11th July 2009
by Xenos Go to last post
0 422
Help

Can't Remove Green Crosshair.

Okay, so I made a Swep from a Desert eagle skin and I can't figure out how to remove the original crosshair.

11th July 2009
by Averice Go to last post
8 1,524
Request

Smashball Grapple Hook

Would it be possible to make a grapple hook that works exactly or close to exactly like the grapple hook in the mod Smashball? The grapple hook in that mod is excellent, and putting it into Gmod would be awesome.

11th July 2009
by awatemonosan Go to last post
8 1,609
Request

Swep Pack

I'm making a Swep Pack from CSS skins right now and I'm up to 6. I want your requests. Rules : No shitty skins that just change the color of the weapon. No Shotguns. (They are annoying to code.) I'm going to release the pack when I get up to 30...

11th July 2009
by mescool15 Go to last post
5 714
Help

DarkRP chat commands

Hey, tell me if this is wrong section, I wanted to know. Anyways if someone could help me make/edit chat commands for Darkrp, I was trying to make a /me that would be locally displayed around the player like ** Joe throws an apple and a /event like,...

11th July 2009
by Jamie932 Go to last post
5 2,150
Question

Steam Avatar texture

Is there anyway to get the texture of someone's avatar without having to use the AvatarImage vui element?

11th July 2009
by SteveUK Go to last post
4 791
Help

Draw or Surface?

Hi, I am trying to create a custom hud. On the Wiki i found these classes: Draw and Surface So my question is, what class should i use for creating my hud and what is the best way of creating it?

11th July 2009
by w00ty Go to last post
4 531
Help

GM:ShowHelp Customization

Hello, I am trying to customize the F1 menu. I created my own index.html, and made it into a website. I have 4 html files I was to use, and all controlled by a CSS that switches between them. How can I do that server side? So when a client presses F1,...

11th July 2009
by Odahilys Go to last post
9 1,371
Help

/ready Lua Help

I have had help creating something that where people type /ready they're basically voting that they're ready to start the round and when 3/4ths of the server type /ready, it will turn on player damage, etc... I have it how I'd like it, but it's not really...

11th July 2009
by Entoros Go to last post
22 1,099
Help

Offer for Scripters

I need someone that knows Lua and Garrysmod very well and will do work for me (Im not planning on doing something super serious, I just want you to edit and add somethings). The catch is I can't pay you but I can offer you admin on the server *shrugs*...

11th July 2009
by Apophis 1 Go to last post
39 1,554
Question

How to stream MP3.

What is the most effective method to stream MP3 files in game?

11th July 2009
by maurits150 Go to last post
9 1,043
Help

Usable NPC

Hey guys, Needing help with a use-able NPC that'll bring up a derma on use. Any ideas where I should start? :D

11th July 2009
by MattGunter Go to last post
2 564
Help

Some Scripting error at dedicated server start up

Someone know what this error means and how can i reapair thanks :D! z_lib and ZeikJT file not found

11th July 2009
by kevkev Go to last post
1 556
Help

Custom Effects

I'm having a hard time making my own effects. The wiki doesn't have much info on them...so, where do I start?

11th July 2009
by braxus Go to last post
0 419
Help

Help parenting volumetric light to light?

I'd like to have it so that when you spawn the industrial lamp, one of the volumetric light objects (64x128) will spawn with it, and move with it, this all works but the industrial lamp does not spawn where I'd like it to. The problem is the industrial...

11th July 2009
by nater Go to last post
0 718
Question

Emitting Streaming Sound

Is it possible to Emit Streaming Sounds/music? Using lua?

11th July 2009
by Skapocalypse Go to last post
8 935
Help

SWEP not in correct category.

My SWEP is basically functional, except that its not apearing in the correct category. My other SWEP doesn't appear at all. I know the category is fine because a 3rd SWEP DOES appear.

12th July 2009
by mescool15 Go to last post
1 482
Help

Need help with creating npc's. plz give walkthrough.

Ihav no idea on what to do in order to create a npc. i have looked at the lua files on wiki.gmod.com and dont understand it, plz help.

12th July 2009
by ReM0cEgR0eG Go to last post
2 491
Help

Limit AUX

For my Gamemode I'm creating, i was wondering if there's a function or command that i could use to limit sprint, or AUX. Power or w/e so that it could be semi-realistic? I need help because i'm fairly new to this stuff. Please Respond.

12th July 2009
by TheGreatVax Go to last post
1 557
Request

Kewl shitz

My graphics card runs Lua really good. Can someone make me an AK47 that shoots babies? 02:14AM Don't ban me for that. You told me to post it in here. 02:15AM Fuck it. Just delete this thread please.

12th July 2009
by TheGreatVax Go to last post
4 425
Question

Admins get certain player models

I was wondering how I would be able to make to so that when a player is an admin on my server, they use a custom "admin" player model?

12th July 2009
by Waffler Go to last post
13 2,282
Help

Making a custome sprite

Hello, i am currently trying to learn more about rendering sprites with lua. i want to create my own sprite to be used in a gamemode i am creating with a friend, as a test i have created a sort of slashing texture i want to render when i attack with a...

12th July 2009
by meka/sniper Go to last post
1 522
Help

Parentheses Help

Where do I need my parentheses here because this is not working: v:ChatPrint(math.Round(#players*0.75)-#ready "more votes required to begin the round.") and yes, #ready and #players exists, it all works except when I add the text.

12th July 2009
by MakeR Go to last post
2 441
Lua

Getting the screen pos of a vgui component.

Hi all. I want to do a OnMouseIn (and OnMouseOut) function, so I need where the mouse is, and where the vgui component is. The mouse is easy, just a function. The problem is to get the screen (or window if windowed mode) relative pos of vgui component. I...

12th July 2009
by lilezek Go to last post
5 675
Help

Download files

Could someone please explain how to use resource.AddFile and sv_downloadurl, I've used them before but I've forgot how to use them in a script.

12th July 2009
by hal2929 Go to last post
3 584
Help

Allowing entities to be 'used'.

I am trying to make various physics props have a menu appear on them when 'use' is pressed while looking at them. To this end, I have run 'entity:SetUseType(SIMPLE_USE)' on all of them. However, only some of them are usable, and they were usable before....

12th July 2009
by Yobdren Go to last post
4 614
Help

Particles

I need to make a gun fire particles. Could someone point me in the right direction, i havent worked with particles yet.

12th July 2009
by almost cool Go to last post
3 581
Help

My character is without a head...

I'm been trying to get my player in thirdperson for a while now, and i've finally accomplished it, without having cheats on (yay me), but he doesn't have a head, or arms... I'm guessing it's because he isn't supposed to be seen from this view or...

12th July 2009
by avwos Go to last post
0 417
Help

For loops failing: "in" expected near "do"

My player_extension.lua won't run properly and will return the error graverobber\gamemode\player_extension.lua:20: 'in' expected near 'do'. I'm not using a table to run the for loop, I just want to execute the code 'n' times. function meta:DropBones(...

12th July 2009
by MakeR Go to last post
3 1,207
Stupid

Scope for a swep?

Well I'm making a swep that needs a scope and I have no clue how to make it. Can someone help me?

12th July 2009
by avwos Go to last post
3 575
Stupid

How do i import the surface and draw libraries in lua

Ok, so my friend is making a scanner welder swep, and gets this error : weapons\scanner_welder\shared.lua:108: attempt to index global 'draw' (a nil value) I dont know a thing about what that means, i donk know lua. Just answer the question in the...

12th July 2009
by Yobdren Go to last post
19 1,101
Request

Combine Over Watch Hunter-Chopper (Attack Heli) Smart Npc.

Hey i was wondering if anyone could pull off an npc such as xystus's Apache helicopter npc that would follow you even if their were no Nodes on a map. It would also drop the bombs,shoot and be able to be killed and have the model of the Hunter Chopper....

12th July 2009
by awatemonosan Go to last post
1 693
Help

Timer.Simple Help

This seems to run the command immediately after it is "triggered", but I would like to have it run 5 secons after it's "triggered". What am I doing wrong. timer.Simple(5, game.ConsoleCommand("changelevel gm_flatgrass\n"))

12th July 2009
by Kogitsune Go to last post
1 498
Help

Help with list like panels.

Ok i'm working on a project code name project dorris. ATM i cant reveal what the project is about so i cant tell you really what i'm trying to make so ill ask a similar question that will return an answer i can make use of. Ok what im trying to do...

12th July 2009
by goluch Go to last post
4 545
Repeat

Gamemode not working when changing folder names.

Dunno what Garry did, but nor GM.Name or Gamemode.Name work as actual ways of changing my gamemode's name on a server, it always has the folder name. And whenever I change the folder name, the gamemode ceases to load. Help?

12th July 2009
by Kogitsune Go to last post
1 504
Question

player.IsWeapon( ) ???!!!??!!

I was looking through the wiki and stumbled across this hilarious piece of a function. Why would we ever need to know if a player is a weapon? Even the wiki says it allways returns false since a player cant be a weapon? Why? Who created this? What...

12th July 2009
by bromvlieg Go to last post
31 1,578
Help

Parenting Volumetric Light to Light?

I'd like to have it so that when you spawn the industrial lamp, one of the volumetric light objects (64x128) will spawn with it, and move with it, this all works but the industrial lamp does not spawn where I'd like it to. The problem is the industrial...

12th July 2009
by nater Go to last post
4 772
Help

help ( 2 Last )

ok i been working on this help menu for darkrp just like the help menu for cop and and mobboss it works and stuff but im not sure where to add the command /x to be able to close the help menu and also the /help.... so all i need is some1 to tell me what...

12th July 2009
by CombineGuru Go to last post
46 1,553
Help

DCollapsibleCategory Problem...

Let's say I have a set of DCollapsibleCategories - does anyone know of a way of making only one of them be maximised at a time? My attempt is shown below, but it doesn't work. Basically, a way of causing clicking any of the categories to make them all...

12th July 2009
by Hysteria100 Go to last post
1 489
Request

more than one weld.

a script that allows for more than one weld between 2 props. currently, the maximum number is 1.

13th July 2009
by urbanmonkey Go to last post
4 434
Request

Atlantis Shield

Okay, I am building a Atlantis base but the normal shield is WAY too small, so could you guys make a atlantis shield that can 1: only burn out if it runs out of power 2: is way bigger the normal shield to fit big bases, and ships

13th July 2009
by Pi-Batt Go to last post
0 605
Help

DModelPanel failing randomly

God, second one today...? Anyway, I've got an issue on my server with people randomly getting vgui/DModelPanel.lua:69: bad argument #1 to 'ClientsideModel' (string expected, got nil) And some not getting it. I originally thought it was an addon,...

13th July 2009
by Big Bang Go to last post
0 531
Help

Can you make Vehicle SNPCs?

I'm wondering if it's possible to make a vehicle SNPCs so this one would drive around like an NPC. ( Think about the APCs from HL2's singleplayer ) Thanks.

13th July 2009
by awatemonosan Go to last post
2 508
Request

Advance Prop Spawner

hey i know the prop spawner was cool, but i think it would be much awesome if it can spawn props with entities on it, just like a guided missile, so i can push a button and it can spawn a guided missile, my apologies if i'm in the wrong forum section

13th July 2009
by DanielPinoy Go to last post
1 470
Lua

COD4 Javelin? ( 2 Last )

Is it possible to make that Javelin with that tracking system? http://youtube.com/watch?v=DC_zKBJhz4w And sorry for going off topic but how do I use the fly by wire and aaraam addon? Also I will try and port these cod4 models once I learn the art of...

13th July 2009
by ray243 Go to last post
68 5,716
Help

Alternates to Network Variables

I'm currently working on a few gamemodes one of which being a roleplay gamemode and was wondering if there were any alternative methods of storing data other than using network variables as they tend to slow down server performance. I've experimented with...

13th July 2009
by Lexic Go to last post
4 595
Request

Poke The Cop gamemode

OK im new to FP so if i did something wrong, tell me. Anyway i once played a game called Poke The Angry Ogre on Warcraft 3 and loved it! The idea of the game was to get points by poking the ogre and not get smashed. The ogers speed rose the more you...

13th July 2009
by Zombie Strider Go to last post
2 529
Question

sbox_max makes me worried :/

Hey Guys. I want a Sbox_Max Function in my Script, its a Swep I created: if (SERVER) then CreateConVar('sbox_max_popcans', 20) end and if !CheckLimit("popcans") then return end

13th July 2009
by m0nst3rkill3r Go to last post
14 1,751
Question

Custom Chatbox (Like in Darkland, perp, etc..)

Does anyone know how to make a custom chat box? I want one sort of like Darklands, with OOC, Local, PM's, and /me commands. I have no idea how to do this. Where could I get started? I could really use help, as I am trying to make a gamemode myself.

13th July 2009
by Limee Go to last post
12 1,852
Love

Scripted NPC (i don't know what they're called)

I need an NPC, that can give missions, trade and give general information, much like the barmen in STALKER. I'm new to LUA, and don't know where to start. ANY help would be much appresiated. Thanks in advance :)

13th July 2009
by avwos Go to last post
2 551
Stupid

My team menu is accessibly with a simple console command

I'm currently making a gamemode, and the team menu is an incredibly simple menu shown in the gameode tutorials on wiki. The team menu is available at any time by typing team_menu in the console. I either want to make the console unavailable (this...

13th July 2009
by Yobdren Go to last post
3 487
Question

Custom loading screen

http://code.garrysmod.com/?into=garrysmod/lua/menu/loading I see it's all lua. So couldn't we just design our own loading screens? Or is that code compiled with garrysmod? or in the GCF? Edit: So if we create a different file in one of their places,...

13th July 2009
by Yobdren Go to last post
18 4,077
Lua

P5 Glove interface.

Any one know of the P5 Glove? It's a VR glove that lets you do this- http://www.youtube.com/watch?v=Cj21S3cLPYk&feature=related And this- http://www.youtube.com/watch?v=288z9K60J3Y&feature=related Could some one make a hand swep that has an...

13th July 2009
by awatemonosan Go to last post
4 502
Help

player_extension.lua:65: attempt to index global 'server_settings'=nil.

Hey Guys. I get that lua error sandbox\gamemode\player_extension.lua:65: attempt to index global 'server_settings'a nil value I cannot find the part of my script who makes that error // The Concommands for Easily Settings local Can_Trail =...

13th July 2009
by m0nst3rkill3r Go to last post
5 1,441
Help

Gamemode help

I want to create a really simple gamemode but i need some basic information first. 1. How can I make a system that adds, say 5 seconds to a variable every 20 seconds? 2. How can I make a system that runs a console command when you press a button, and...

13th July 2009
by laptopman Go to last post
8 715
Lua

Sql error.

Hi everyone. sql.LastError() is retrieving me "column name is not unique". Which kind of error is this? How I should fix it?

13th July 2009
by lilezek Go to last post
3 635
Help

Dark rp problems with coding

Thank you for reading. Hopefully you can help me. I edit my addshipments lua. file ( the file is located in C:\Program Files\Steam\steamapps\User name\garrysmod\garrysmod\gamemodes\DarkRP\gamemode ) in Dark Rp to make shipments for a job called...

13th July 2009
by spazar Go to last post
2 697