gamedata/sdktools.games/engine.l4d.txt
changeset 2524 b7d445920806
child 2535 b3bfd3c1ad9f
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/gamedata/sdktools.games/engine.l4d.txt	Mon Jan 12 02:28:22 2009 -0500
     1.3 @@ -0,0 +1,346 @@
     1.4 +"Games"
     1.5 +{
     1.6 +	/* Sounds */
     1.7 +	"#default"
     1.8 +	{
     1.9 +		"Keys"
    1.10 +		{
    1.11 +			"SlapSoundCount"	"2"
    1.12 +			"SlapSound1"		"player/damage1.wav"
    1.13 +			"SlapSound2"		"player/damage2.wav"
    1.14 +		}
    1.15 +	}
    1.16 +	
    1.17 +	/* General Temp Entities */
    1.18 +	"#default"
    1.19 +	{
    1.20 +		"#supported"
    1.21 +		{
    1.22 +			"game"		"left4dead"
    1.23 +		}
    1.24 +
    1.25 +		"Offsets"
    1.26 +		{
    1.27 +			/* Offset into CBaseTempEntity constructor */
    1.28 +			"s_pTempEntities"
    1.29 +			{
    1.30 +				"windows"	"17"
    1.31 +			}
    1.32 +			"GetTEName"
    1.33 +			{
    1.34 +				"windows"	"4"
    1.35 +				"linux"		"4"
    1.36 +			}
    1.37 +			"GetTENext"
    1.38 +			{
    1.39 +				"windows"	"8"
    1.40 +				"linux"		"8"
    1.41 +			}
    1.42 +			"TE_GetServerClass"
    1.43 +			{
    1.44 +				"windows"	"0"
    1.45 +				"linux"		"0"
    1.46 +			}
    1.47 +		}
    1.48 +
    1.49 +		"Signatures"
    1.50 +		{
    1.51 +			"CBaseTempEntity"
    1.52 +			{
    1.53 +				"library"	"server"
    1.54 +				"windows"	"\x8B\xC1\x8B\x4C\x24\x04\xC7\x00\x2A\x2A\x2A\x2A\x89\x48\x04\x8B\x15\x2A\x2A\x2A\x2A\x89\x50\x08\xA3\x2A\x2A\x2A\x2A\xC2\x04\x00"
    1.55 +			}
    1.56 +			"s_pTempEntities"
    1.57 +			{
    1.58 +				"library"	"server"
    1.59 +				"linux"		"@_ZN15CBaseTempEntity15s_pTempEntitiesE"
    1.60 +			}
    1.61 +		}
    1.62 +	}
    1.63 +	
    1.64 +	/* Create Entity Signatures */
    1.65 +	"#default"
    1.66 +	{
    1.67 +		"#supported"
    1.68 +		{
    1.69 +			"game"		"left4dead"
    1.70 +		}
    1.71 +
    1.72 +		"Signatures"
    1.73 +		{
    1.74 +			"DispatchSpawn"
    1.75 +			{
    1.76 +				"library"	"server"
    1.77 +				"linux"		"@_Z13DispatchSpawnP11CBaseEntity"
    1.78 +				"windows"	"\x53\x55\x56\x8B\x74\x24\x10\x85\xF6\x57\x0F\x84\x2A\x2A\x2A\x2A\x8B\x1D\x2A\x2A\x2A\x2A\x8B\x03\x8B\x50\x64\x8B\xCB"
    1.79 +			}
    1.80 +			"CreateEntityByName"
    1.81 +			{
    1.82 +				"library"	"server"
    1.83 +				"linux"		"@_Z18CreateEntityByNamePKcib"
    1.84 +				"windows"	"\x56\x8B\x74\x24\x0C\x83\xFE\xFF\x57\x8B\x7C\x24\x0C\x74\x27\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x8B\x50\x54\x56\xFF\xD2"
    1.85 +			}
    1.86 +		}
    1.87 +	}
    1.88 +
    1.89 +	/* CGlobalEntityList */
    1.90 +	"#default"
    1.91 +	{
    1.92 +		"#supported"
    1.93 +		{
    1.94 +			"game"		"left4dead"
    1.95 +		}
    1.96 +		
    1.97 +		"Offsets"
    1.98 +		{
    1.99 +			/* Offset into LevelShutdown */
   1.100 +			"gEntList"
   1.101 +			{
   1.102 +				"windows"	"11"
   1.103 +			}
   1.104 +		}
   1.105 +		
   1.106 +		"Signatures"
   1.107 +		{
   1.108 +			"LevelShutdown"
   1.109 +			{
   1.110 +				"library"	"server"
   1.111 +				"windows"	"\xE8\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\xB9\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\xE8"
   1.112 +			}
   1.113 +			"gEntList"
   1.114 +			{
   1.115 +				"library"	"server"
   1.116 +				"linux"		"@gEntList"
   1.117 +			}
   1.118 +			
   1.119 +			/* Functions in CGlobalEntityList */
   1.120 +			"FindEntityByClassname"
   1.121 +			{
   1.122 +				"library"	"server"
   1.123 +				"windows"	"\x53\x55\x56\x8B\xF1\x8B\x4C\x24\x10\x85\xC9\x57\x74\x19\x8B\x01\x8B\x50\x08\xFF\xD2\x8B\x00\x25\xFF\x0F\x00\x00\x83\xC0\x01\xC1\xE0\x04\x8B\x3C\x30\xEB\x06\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x39\x8B\x5C\x24\x18\x8B\x2D\x2A\x2A\x2A\x2A\xEB\x03"
   1.124 +				"linux"		"@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
   1.125 +			}
   1.126 +		}
   1.127 +	}
   1.128 +
   1.129 +	/* General GameRules */
   1.130 +	"#default"
   1.131 +	{
   1.132 +		"#supported"
   1.133 +		{
   1.134 +			"game"		"left4dead"
   1.135 +		}
   1.136 +		
   1.137 +		"Offsets"
   1.138 +		{
   1.139 +			/* Offset into CreateGameRulesObject */
   1.140 +			"g_pGameRules"
   1.141 +			{
   1.142 +				"windows"	"2"
   1.143 +			}
   1.144 +		}
   1.145 +		
   1.146 +		"Signatures"
   1.147 +		{
   1.148 +			/* This signature sometimes has multiple matches, but this
   1.149 +			 * does not matter as g_pGameRules is involved in all of them.
   1.150 +			 * The same g_pGameRules offset applies to each match.
   1.151 +			 *
   1.152 +			 * Sometimes this block of bytes is at the beginning of the static
   1.153 +			 * CreateGameRulesObject function and sometimes it is in the middle
   1.154 +			 * of an entirely different function. This depends on the game.
   1.155 +			 */
   1.156 +			"CreateGameRulesObject"
   1.157 +			{
   1.158 +				"library"	"server"
   1.159 +				"windows"	"\x8B\x0D\x2A\x2A\x2A\x2A\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2A\x6A\x01\xFF\xD2"
   1.160 +			}
   1.161 +			"g_pGameRules"
   1.162 +			{
   1.163 +				"library"	"server"
   1.164 +				"linux"		"@g_pGameRules"
   1.165 +			}
   1.166 +		}
   1.167 +	}
   1.168 +
   1.169 +	/* IServer interface pointer */
   1.170 +	"#default"
   1.171 +	{
   1.172 +		"Offsets"
   1.173 +		{
   1.174 +			/* Offset into IVEngineServer::CreateFakeClient */
   1.175 +			"sv"
   1.176 +			{
   1.177 +				"windows"	"6"
   1.178 +			}
   1.179 +		}
   1.180 +
   1.181 +		"Signatures"
   1.182 +		{
   1.183 +			/* CBaseServer object for IServer interface */
   1.184 +			"sv"
   1.185 +			{
   1.186 +				"library"	"engine"
   1.187 +				"linux"		"@sv"
   1.188 +			}
   1.189 +		}
   1.190 +	}
   1.191 +	
   1.192 +	/* EntityFactoryDictionary function */
   1.193 +	"#default"
   1.194 +	{
   1.195 +		"Signatures"
   1.196 +		{
   1.197 +			"EntityFactory"
   1.198 +			{
   1.199 +				"library"	"server"
   1.200 +				"windows"	"\xB8\x01\x00\x00\x00\x84\x2A\x2A\x2A\x2A\x2A\x75\x1D\x09\x2A\x2A\x2A\x2A\x2A\xB9\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\x68\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\x83\xC4\x04\xB8\x2A\x2A\x2A\x2A\xC3"
   1.201 +				"linux"		"@_Z23EntityFactoryDictionaryv"
   1.202 +			}
   1.203 +		}
   1.204 +	}
   1.205 +
   1.206 +	/* CBaseEntityOutput::FireOutput */
   1.207 +	"#default"
   1.208 +	{
   1.209 +		"#supported"
   1.210 +		{
   1.211 +			"game"		"left4dead"
   1.212 +		}
   1.213 +		"Signatures"
   1.214 +		{
   1.215 +			"FireOutput"
   1.216 +			{
   1.217 +				"library"	"server"
   1.218 +				"windows"	"\x81\xEC\x1C\x01\x00\x00\x53\x55\x56\x8B\x71\x14\x85\xF6"
   1.219 +				"linux"		"@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
   1.220 +			}
   1.221 +		}
   1.222 +		"Offsets"
   1.223 +		{
   1.224 +			"FireOutputBackup"
   1.225 +			{
   1.226 +				"windows"	"6"
   1.227 +				"linux"		"10"
   1.228 +			}
   1.229 +		}
   1.230 +	}
   1.231 +	
   1.232 +	/* SetUserInfo data */
   1.233 +	"#default"
   1.234 +	{
   1.235 +		"Offsets"
   1.236 +		{
   1.237 +			/**
   1.238 +			 * CBaseClient::SetUserCVar(char  const*,char  const*);
   1.239 +			 * Linux offset straight from VTable dump.
   1.240 +			 * Windows offset is crazy. Found the windows 'SetName' function using string "(%d)%-0.*s"
   1.241 +			 * Cross referenced back to the vtable and counted manually (SetUserCvar is 1 higher, offsets start from 1)
   1.242 +			 */
   1.243 +			"SetUserCvar"
   1.244 +			{
   1.245 +				"windows"	"17"
   1.246 +				"linux"		"62"
   1.247 +			}
   1.248 +			/**
   1.249 +			 * Offset into CBaseClient - Used by CBaseServer::UpdateUserSettings to determine when changes have been made.
   1.250 +			 * Find CBaseClient::UpdateUserSettings (strings "net_maxroutable", "cl_updaterate" etc) and the offset is set to 0 near the end.
   1.251 +			 * Linux: 	mov     byte ptr [esi+0B0h], 0
   1.252 +			 * Win:		mov     byte ptr [esi+0B0h], 0
   1.253 +			 */
   1.254 +			"InfoChanged"
   1.255 +			{
   1.256 +				"windows"	"176"
   1.257 +				"linux"		"176"
   1.258 +			}
   1.259 +		}
   1.260 +	}
   1.261 +	
   1.262 +	/* Left 4 Dead */
   1.263 +	"left4dead"
   1.264 +	{
   1.265 +		"Offsets"
   1.266 +		{
   1.267 +			"GiveNamedItem"
   1.268 +			{
   1.269 +				"windows"	"480"
   1.270 +				"linux"		"481"
   1.271 +			}
   1.272 +			"RemovePlayerItem"
   1.273 +			{
   1.274 +				"windows"	"269"
   1.275 +				"linux"		"270"
   1.276 +			}
   1.277 +			"Weapon_GetSlot"
   1.278 +			{
   1.279 +				"windows"	"267"
   1.280 +				"linux"		"268"
   1.281 +			}
   1.282 +			"Ignite"
   1.283 +			{
   1.284 +				"windows"	"206"
   1.285 +				"linux"		"207"
   1.286 +			}
   1.287 +			"Extinguish"
   1.288 +			{
   1.289 +				"windows"	"210"
   1.290 +				"linux"		"211"
   1.291 +			}
   1.292 +			"Teleport"
   1.293 +			{
   1.294 +				"windows"	"105"
   1.295 +				"linux"		"106"
   1.296 +			}
   1.297 +			"CommitSuicide"
   1.298 +			{
   1.299 +				"windows"	"449"
   1.300 +				"linux"		"449"
   1.301 +			}
   1.302 +			"GetVelocity"
   1.303 +			{
   1.304 +				"windows"	"136"
   1.305 +				"linux"		"137"
   1.306 +			}
   1.307 +			"EyeAngles"
   1.308 +			{
   1.309 +				"windows"	"127"
   1.310 +				"linux"		"128"
   1.311 +			}
   1.312 +			"AcceptInput"
   1.313 +			{
   1.314 +				"windows"	"37"
   1.315 +				"linux"		"38"
   1.316 +			}
   1.317 +			"DispatchKeyValue"
   1.318 +			{
   1.319 +				"windows"	"29"
   1.320 +				"linux"		"28"
   1.321 +			}
   1.322 +			"DispatchKeyValueFloat"
   1.323 +			{
   1.324 +				"windows"	"28"
   1.325 +				"linux"		"29"
   1.326 +			}
   1.327 +			"DispatchKeyValueVector"
   1.328 +			{
   1.329 +				"windows"	"27"
   1.330 +				"linux"		"30"
   1.331 +			}
   1.332 +			"SetEntityModel"
   1.333 +			{
   1.334 +				"windows"	"23"
   1.335 +				"linux"		"24"
   1.336 +			}
   1.337 +			"WeaponEquip"
   1.338 +			{
   1.339 +				"windows"	"260"
   1.340 +				"linux"		"261"
   1.341 +			}
   1.342 +			"Activate"
   1.343 +			{
   1.344 +				"windows"	"31"
   1.345 +				"linux"		"32"
   1.346 +			}
   1.347 +		}
   1.348 +	}
   1.349 +}