![]() |
|
Close Help |
Introduction to Half-Life SDK2"If I see windows.h included anywhere but vgui\lib-src\win32 I will hunt you down and kill you. Don't give me any crap that mfc is platform inspecific." Anon, VGUI.h |
|
SDK2 Directory Structure and Files
|
|
sdk |
Root directory. Contains a few
Word Docs that give an idea what sort of things are possible with the SDK.
|
Launcher Strings | A stringtable containing all the error messages that can be produced by the client. e.g. Direct Draw Init failed, Network problems etc. I'm not sure why this is in a separate directory, but you are unlikely to need to change anything here unless you're doing something really drastic, or you're developing a foreign language MOD. |
Map Files | Some example levels from Half-Life in WorldCraft format .rmf files. These are handy if you want to see how some of the original Half-Life levels are put together. However, there are also tools around (such as WinBSP http://www.botepidemic.com/gladiator/download.shtml ) that enable you to decompile levels directly from the .pak file, and edit them in Worldcraft |
Map Tools | Copies of qbsp, qrad etc. that you need to compile up levels. If you've done any level editing you'll have copies of these already. |
Model Tools | StudioMdl - an export utiltiy for 3D Studio MAX that allows you to save your monster/weapon/player models as Half-Life compatibly .mdl files. You'll only need this if you insist on using the overpriced, unstable and clunky 3D Studio Max for your modelling. If you're sensible you'll go out and use MilkShape 3D for $20 instead (http://www.swissquake.ch/chumbalum-soft). |
Monster Models | 3D Studio Max versions of some of the monster models. Handy for basing your new monsters on, but you can decompile the models from the .pak file using Pakexplorer and Milkshape 3D anyway. |
OldSourceCode | The original SDK1 source code. Not much use, since everything here is contained in the SDK2 "SourceCode" directory anyway. |
Player Models | The source files to the player models that shipped with Half-Life. Again, these should serve as good templates for building custom human models. |
Server Info | A single text file that contains some info about the network protocol, and some example C code. |
Shell | The bitmaps that form the main menu within Half-Life. Handy if you want to skin the main menu in your mod (change the font, colours etc.) |
SourceCode | This is the real stuff! See expanded section below |
Sprite Tools | Tools + articles to build custom 2D sprites within Half-Life. Sprites are useful if you want to add new environmental effects, such as lasers/explosions/steam etc. |
Texture WAD Tools | Some info + utilities for creating new textures in your Half-Life levels. If you want to handle textures, skip this and get a copy of Wally instead (http://www.telefragged.com/wally) it's much better. |
Weapon Models | The 3D Studio Max versions of all the weapons in Half-Life. Also an overview of how to create new weapons in Half-Life. |
WorldCraft | WorldCraft 3.3 Level Editor. This is an application that allows you to build custom levels for Half-Life. But you knew that already, didnt you ?? |
Source Code Directory Structure and Files
|
|
cl_dll | The client DLL. This is the stuff that shipped with the original SDK1. It contains all the source code to the client interface - so if you want to change the appearance of the HUD, weapons display, flashlight, multi-player menus, messages etc. come here. There are lots of articles on programming the client DLL on the SDK1 sites (see SDK2 Main Links for a list). |
common | Some .h header files that are used in both the client and the game engine DLLs. |
dedicated | Source code for building a dedictated multi-player server. Doesnt seem to be as well documented/commented as the other source code. Contains some files relevant to compiling under Linux. |
dlls | The game DLL, with the bulk of the new source code in the SDK2 release. This contains all the monster code, AI, entity code (all those triggers, buttons, multi_managers, objects etc.), weapons (damage, effects etc.), game rules (damage, start/end game, combat etc.). |
engine | Some .h header files that contain the interface to the underlying Quake engine by ID. N.B. you dont get the source code to the Quake engine, unfortunately. |
network | This contains a file, delta.lst,that contains the definition of the data structures sent over the network in a multiplayer game. If you want to add new functionality to a multi-player game, such as events, commands, chat etc. you'll need to use this to define how the messages are sent and interpreted by the clients + server. |
pm_shared | Some .c and .h files that refer to player physics (movement of players, speed, friction etc). This code is shared between the game and client dlls. See PlayerPhysics.doc in the root directory of the sdk. |
utils | C Source code to a whole load of utilities. If you fancy rewriting the BSP, texture, lighting, sprite generation tools etc. come in here. Probably not a great deal of use, unless you want to write your own utilities. |
Next Tutorial... Introduction to the Sourcecode: Basic classes in the client and game
DLLs
|