Half-Life 2 SDK?

Q

qckbeam

Guest
Ok, I am not really new to programming, but I have never been able to sit down and write code for the programs I wanted to create. For example, I learned the simple programming language Python months ago, I was more than able to make simple programs with no real use to me, but when I wanted to take the knowledge I had about Python and use it to create a simple game engine I had no idea where to begin or what I should do. I knew what I had to do to create an engine and I knew what the format of the engine would be, but I could never figure out what I had to do when it came time to sit down and write the code. I eventually just gave up with Python and my game engine idea. I do understand the theory behind programming, even the more advanced topics. Now I also learned C++ about two years back and again I could program stupid programs which had no real use to me. I thought I was prepared for the Half-Lfie SDK but when I got it and read it it was like reading, well... code. I understood some stuff but not enough to do any modding to the game. My question to you all is, what do I have to learn to read these SDK's. I can get a 500 page book, sit down and read the whole damn thing, apply what I have learned, practice for months, and when I get to the SDK... nothing. Please, what the hell am I doing wrong. Am I just stupid or something, because I really want to open up the Half-Life 2 SDK and understand what I read. I want to be able to be able to add my own modifications to the game, but I have really been stuck here for the past two years. Please help. Thanks.
 
im assuming you have read lots of HL programming tutorials, if not they will show you how to do some basic stuff in the SDK. then you can put what you know into it and do stuff and stuff. Also there are some that show you what parts of the SDK actually mean. other than that its just a bunch of classes and methods and shizzle.

happy coding
 
My suggestion would be to try tackling a very specific problem to start out, for example: "I want the glock to shoot faster and for the clip to be larger." Then go through the code and use trial and error if you have to. Once you figure out where the guns are defined in the SDK its a simple matter to make little changes like those and compile them. Then move up a step and try something like making it so zombies can only be hurt with the crowbar. As you run into obstacles, search for answers with google or ask questions on forums.

This is the way that works best for me when I'm trying to learn new code: go in with a specific problem you want to solve, and do whatever it takes to solve it. It's really not necessary to understand all the code, you only need to understand the most important pieces that influence the part you're working on. As you solve more difficult problems you'll gradually recognize more of the code and pretty soon you'll be able to read it like a book.
 
Thanks, so far you guys have both given really good advice. With this upcoming SDK I will try and start with really simple stuff, small projects. One thing that always tripped me up is compiling documents after you have changed them. Is there anywhere I can go to find a good tutorial on how to do this, I'm not going to start modding HL1 but I would like to be able to have some experience with it for the HL2 SDK. Thanks.
 
There are several good books out there in the market that explains how to make games and such in C++. Maybe you should read a few to get a better understanding of video game programming. Check places like www.amazon.com. There are also good books that teach C++ also. If there is something you don't understand or are rusty on you should probably look over one of those also.
 
Hey guys! Thanx alot for your help. I'm learning C++ slowly but surely and you guys helped. In HL2, you'll certainly see an amazing mod.
 
I was in the exact same boat myself until just recently.

My advice is to start working with the HL1 SDK to get i practice for HL2.

Here's 3 good sites that have tutorials that mostly work on the new SDK:

HL Programming Planet
vERC
Wavelength

I suggest you just start w/ the tutorials that has stuff like coding a new weapon or implementing teamplay. The thing is, most of the tutorials are broken, so you'll actually learn quite a bit by debugging and fixing them. Its a very very steep learning curve right at first, but once you get the hang of it you can start feeling l33t about coding stuff once you get to the point where you can write your own bits of stuff w/o any tutorials. :)
 
i had the same problem. i sat there wrinting little calculators or programs which swapped variables but couldn't get further. until my computer science teacher tought me that it isn't important to know al thesse methods, class definitions etc.. by heart but that you first think really clearly about what you want to do. than make a picture of the process where it would end, with which result, for every case, if(), while() etc.. also start by reading small code of programs which you can't code on your own. try to understand their basics. e.g. take an irc client. try to find the method which establishs the socket to the irc server ..leave out the fancy stuff like colors etc and write one on your own.
 
Back
Top