Source Entities:Entity pages

Src Ents has a somewhat complex system for documenting entities. Do note that every entity will have a page for the classname, and a page for the code class. (don't freak out, it's actually not that bad)

First, are you making a page for the code class or the classname?
 * Code class
 * Classname

The rest of this page is a small FAQ devoted to answering some questions editors may have.

How can I find entity info if it's not in the FGDs?
Logically, search in code. Here's some public code repos:
 * https://github.com/VSES/SourceEngine2007/ - Source 2007 games. This code was illegal to host publicly, but Valve has decided to let it be public.
 * Half-Life 2
 * Episodic
 * DODS
 * CSS
 * Portal
 * TF2 (though, since tf2 is still being maintained and changed over a decade later, the tf2-related code can be inaccurate and incomplete)
 * HL:S
 * Valve's unfinished TFC port to Source
 * Lost Coast
 * HL2DM
 * Some other things like ep3 and a few SDK tools
 * https://github.com/NicolasDe/AlienSwarm/ - This is simply a copy of the code that ASW is bundled with. Handy if you don't have that game downloaded.
 * It's mainly Alien Swarm only, though apparently there's some leftovers from other games here and there
 * https://github.com/raxxor45/ValveSecurity/ - Relatively recent leak.
 * Has most of the same stuff you'll find in the VSES SourceEngine2007 leak, but we do know it has some previously unknown SDK tools that Valve has never released.
 * https://github.com/ValveSoftware/halflife/ - Valve's official repo for GoldSrc games.
 * It seems like this repo only has code for HL, ricochet, and DMC.

To find the code class associated with an entity, look for a macro called. It will have the classname and the code class next to each other.

To find what class another class inherits from, search for. Be careful cause sometimes multiple classes will be listed even though they aren't "entity" classes.

The bulk of the data we need will be in what's called the data description. Find this by looking for the  macro. This will not include some keyvalues. Be sure to also check for anything under the function  if it exists. Flags are usually done like this: There's no standard way to define flags apparently, though this is the most common.
 * 1) define	SF_ENVEXPLOSION_NODAMAGE	0x00000001 // when set, ENV_EXPLOSION will not actually inflict damage
 * 2) define	SF_ENVEXPLOSION_REPEATABLE	0x00000002 // can this entity be refired?
 * 3) define SF_ENVEXPLOSION_NOFIREBALL	0x00000004 // don't draw the fireball
 * 4) define SF_ENVEXPLOSION_NOSMOKE		0x00000008 // don't draw the smoke
 * 5) define SF_ENVEXPLOSION_NODECAL		0x00000010 // don't make a scorch mark
 * 6) define SF_ENVEXPLOSION_NOSPARKS	0x00000020 // don't make sparks
 * 7) define SF_ENVEXPLOSION_NOSOUND		0x00000040 // don't play explosion sound.

What if the game doesn't have public code?
You'll need these. These will show you everything except for flags and keyvalues that got defined through the  method. Unfortunately, we haven't been able to get a datamap for DODS but you can still check datadescs in code.

We also have every stock FGD uploaded, so you can find info you need there as well if it's something not in the datamaps.

This is a LOT of data!
http://diffchecker.com/ this site can make it a little easier.