wallweasels
07-25-2010, 09:53 PM
So I'm rather confused on how to make new weapons here. weapons seem to be a few things:
the models (mdl, ctx, etc), the .txt script (damage, firespeed, reload speed, sounds it uses), and the .cpp/.h (the code of what it does).
Basically I want to make a "freeze" flamethrower. For simplicity I Just wanted to change the alt-fire extinguisher to be "ice gun". This seemed pretty simple...find out what makes the sentry freeze people, and then apply it to the flamethrower instead of the extinguishing. However, I can't find where to put the .cpp files in the addon folder. :| I think I need to tell the script file to use it, but I don't know how. Am I missing something here?
Is there a reslist or weapons list file that I need to modify in order to put tell it to use the new .cpp or does the .cpp file have a specific folder. I've tried finding it...but there seems to be no game directory for .cpp files in the .vpk :o
I admit, I am not an experienced coder or anything so I could just be doing this wrong. So if someone could tell me a "step 1/2/3+" of making a new weapon or changing an existing weapon (outside of damage done and easy stuff like that) that would be great.
tl;dr: How the hell do you make a custom weapon?
Also yes, I just lurk the forums, this is my first post :cool:
the models (mdl, ctx, etc), the .txt script (damage, firespeed, reload speed, sounds it uses), and the .cpp/.h (the code of what it does).
Basically I want to make a "freeze" flamethrower. For simplicity I Just wanted to change the alt-fire extinguisher to be "ice gun". This seemed pretty simple...find out what makes the sentry freeze people, and then apply it to the flamethrower instead of the extinguishing. However, I can't find where to put the .cpp files in the addon folder. :| I think I need to tell the script file to use it, but I don't know how. Am I missing something here?
Is there a reslist or weapons list file that I need to modify in order to put tell it to use the new .cpp or does the .cpp file have a specific folder. I've tried finding it...but there seems to be no game directory for .cpp files in the .vpk :o
I admit, I am not an experienced coder or anything so I could just be doing this wrong. So if someone could tell me a "step 1/2/3+" of making a new weapon or changing an existing weapon (outside of damage done and easy stuff like that) that would be great.
tl;dr: How the hell do you make a custom weapon?
Also yes, I just lurk the forums, this is my first post :cool: