Hey guys, I cant find the SWEP I made. I have it located in C:\Program Files (x86)\Steam\steamapps\common\GarrysMod\garrysmod\lua\weapons\weapon_gun. After having somebody look it over I’ve been told its probably a problem with my coding. So I was wondering if anybody could take a look to see if something’s wrong cause I’m completely new to this and have never done this before. http://pastebin.com/Rpwkr93b
Looks like you forgot to AddCSLuaFile() the gun. Just add it onto the first line.
You mean on the first line, like where it says SWEP.PrintName = “Test Gun” Or to move that down one line and then put AddCSLuaFile()?
Why do you ask question if you can test that yourself? Basically it will work both ways, just don’t put in inside any functions.
I did both ways, however it didnt work, still nothing in my spawnlists.
I do believe this is the error
Calvin. If i was you i would find a etc. m16 swep and see how that is made to give you some inspiration. Im sorry that I cant help with your problem because Im not the best lua coder in the world but if I was you i would follow a template or something?
Hope you find an answer
thanks I’ll try that, sorry for not responding, I was on vacation.
[editline]24th June 2013[/editline]
It worked thanks!