Update Nuclear Dawn gamedata.
authorNicholas Hastings <skamonkey@gmail.com>
Sun Apr 20 21:38:40 2014 -0400 (2014-04-20)
changeset 4323142b0c03e6bb
parent 4322 74cb2e0ab2ae
child 4324 f93e67044fa7
Update Nuclear Dawn gamedata.
gamedata/sdkhooks.games/game.nucleardawn.txt
gamedata/sdktools.games/engine.l4d2.txt
gamedata/sdktools.games/game.nucleardawn.txt
     1.1 --- a/gamedata/sdkhooks.games/game.nucleardawn.txt	Sun Apr 20 21:07:28 2014 -0400
     1.2 +++ b/gamedata/sdkhooks.games/game.nucleardawn.txt	Sun Apr 20 21:38:40 2014 -0400
     1.3 @@ -24,9 +24,9 @@
     1.4  			}
     1.5  			"GroundEntChanged"
     1.6  			{
     1.7 -				"windows"	"198"
     1.8 -				"linux"		"199"
     1.9 -				"mac"		"199"
    1.10 +				"windows"	"199"
    1.11 +				"linux"		"200"
    1.12 +				"mac"		"200"
    1.13  			}
    1.14  			"OnTakeDamage"
    1.15  			{
    1.16 @@ -36,21 +36,21 @@
    1.17  			}
    1.18  			"PreThink"
    1.19  			{
    1.20 -				"windows"	"367"
    1.21 -				"linux"		"368"
    1.22 -				"mac"		"368"
    1.23 -			}
    1.24 -			"PostThink"
    1.25 -			{
    1.26  				"windows"	"368"
    1.27  				"linux"		"369"
    1.28  				"mac"		"369"
    1.29  			}
    1.30 +			"PostThink"
    1.31 +			{
    1.32 +				"windows"	"369"
    1.33 +				"linux"		"370"
    1.34 +				"mac"		"370"
    1.35 +			}
    1.36  			"Reload"
    1.37  			{
    1.38 -				"windows"	"291"
    1.39 -				"linux"		"292"
    1.40 -				"mac"		"292"
    1.41 +				"windows"	"292"
    1.42 +				"linux"		"293"
    1.43 +				"mac"		"293"
    1.44  			}
    1.45  			"SetTransmit"
    1.46  			{
    1.47 @@ -114,34 +114,34 @@
    1.48  			}
    1.49  			"Weapon_CanSwitchTo"
    1.50  			{
    1.51 -				"windows"	"296"
    1.52 -				"linux"		"297"
    1.53 -				"mac"		"297"
    1.54 +				"windows"	"297"
    1.55 +				"linux"		"298"
    1.56 +				"mac"		"298"
    1.57  			}
    1.58  			"Weapon_CanUse"
    1.59  			{
    1.60 -				"windows"	"290"
    1.61 -				"linux"		"291"
    1.62 -				"mac"		"291"
    1.63 -			}
    1.64 -			"Weapon_Drop"
    1.65 -			{
    1.66 -				"windows"	"293"
    1.67 -				"linux"		"294"
    1.68 -				"mac"		"294"
    1.69 -			}
    1.70 -			"Weapon_Equip"
    1.71 -			{
    1.72  				"windows"	"291"
    1.73  				"linux"		"292"
    1.74  				"mac"		"292"
    1.75  			}
    1.76 -			"Weapon_Switch"
    1.77 +			"Weapon_Drop"
    1.78  			{
    1.79  				"windows"	"294"
    1.80  				"linux"		"295"
    1.81  				"mac"		"295"
    1.82  			}
    1.83 +			"Weapon_Equip"
    1.84 +			{
    1.85 +				"windows"	"292"
    1.86 +				"linux"		"293"
    1.87 +				"mac"		"293"
    1.88 +			}
    1.89 +			"Weapon_Switch"
    1.90 +			{
    1.91 +				"windows"	"295"
    1.92 +				"linux"		"296"
    1.93 +				"mac"		"296"
    1.94 +			}
    1.95  		}
    1.96  		
    1.97  		"Signatures"
     2.1 --- a/gamedata/sdktools.games/engine.l4d2.txt	Sun Apr 20 21:07:28 2014 -0400
     2.2 +++ b/gamedata/sdktools.games/engine.l4d2.txt	Sun Apr 20 21:38:40 2014 -0400
     2.3 @@ -82,6 +82,11 @@
     2.4  	/* SetUserInfo data */
     2.5  	"#default"
     2.6  	{
     2.7 +		"#supported"
     2.8 +		{
     2.9 +			"game"		"left4dead2"
    2.10 +		}
    2.11 +		
    2.12  		"Offsets"
    2.13  		{
    2.14  			/**
     3.1 --- a/gamedata/sdktools.games/game.nucleardawn.txt	Sun Apr 20 21:07:28 2014 -0400
     3.2 +++ b/gamedata/sdktools.games/game.nucleardawn.txt	Sun Apr 20 21:38:40 2014 -0400
     3.3 @@ -10,7 +10,7 @@
     3.4  			/* Offset into CBaseTempEntity constructor */
     3.5  			"s_pTempEntities"
     3.6  			{
     3.7 -				"windows"	"17"
     3.8 +				"windows"	"19"
     3.9  			}
    3.10  			"GetTEName"
    3.11  			{
    3.12 @@ -37,7 +37,7 @@
    3.13  			"CBaseTempEntity"
    3.14  			{
    3.15  				"library"	"server"
    3.16 -				"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"
    3.17 +				"windows"	"\x55\x8B\xEC\x8B\xC1\x8B\x4D\x08\xC7\x2A\x2A\x2A\x2A\x2A\x89\x48\x04\x8B"
    3.18  			}
    3.19  			"s_pTempEntities"
    3.20  			{
    3.21 @@ -63,7 +63,7 @@
    3.22  			"FindEntityByClassname"
    3.23  			{
    3.24  				"library"	"server"
    3.25 -				"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"
    3.26 +				"windows"	"\x55\x8B\xEC\x53\x56\x8B\xF1\x8B\x4D\x08\x57\x85\xC9\x74\x16\x8B\x01\x8B\x50\x08\xFF\xD2\x8B\x00\x25\xFF\x0F\x00\x00\x40\x03\xC0\x8B\x3C\xC6\xEB\x06\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x31\x8B"
    3.27  				"linux"		"@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
    3.28  				"mac"		"@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
    3.29  			}
    3.30 @@ -83,7 +83,7 @@
    3.31  			 * the expected code. A pointer to sv (IServer interface) is used
    3.32  			 * here.
    3.33  			 */
    3.34 -			"CreateFakeClient_Windows"	"\x8B\x44\x24\x2A\x50\xB9\x2A\x2A\x2A\x2A\xE8"
    3.35 +			"CreateFakeClient_Windows"	"\x55\x8B\xEC\x8B\x45\x08\x50\xB9"
    3.36  		}
    3.37  		
    3.38  		"Offsets"
    3.39 @@ -91,7 +91,7 @@
    3.40  			/* Offset into IVEngineServer::CreateFakeClient */
    3.41  			"sv"
    3.42  			{
    3.43 -				"windows"	"6"
    3.44 +				"windows"	"8"
    3.45  			}
    3.46  		}
    3.47  
    3.48 @@ -107,39 +107,74 @@
    3.49  		}
    3.50  	}
    3.51  	
    3.52 +	/* SetUserInfo data */
    3.53 +	"#default"
    3.54 +	{
    3.55 +		"Offsets"
    3.56 +		{
    3.57 +			/**
    3.58 +			 * CBaseClient::SetUserCVar(char  const*,char  const*);
    3.59 +			 * Linux offset straight from VTable dump.
    3.60 +			 * Windows offset is crazy. Found the windows SetName function using string "(%d)%-.*s" (aD_S in IDA)
    3.61 +			 * Cross referenced back to the vtable and counted manually (SetUserCvar is 1 higher, offsets start from 1)
    3.62 +			 */
    3.63 +			"SetUserCvar"
    3.64 +			{
    3.65 +				/* Not 100% sure on this, why would windows change and not linux - TEST ME */
    3.66 +				"windows"	"17"
    3.67 +				"linux"		"63"
    3.68 +				"mac"		"63"
    3.69 +			}
    3.70 +			/**
    3.71 +			 * Offset into CBaseClient - Used by CBaseServer::UpdateUserSettings to determine when changes have been made.
    3.72 +			 * Find CBaseClient::UpdateUserSettings (strings "net_maxroutable", "cl_updaterate" etc) and the offset is set to 0 near the end.
    3.73 +			 * Linux: 	mov     byte ptr [esi+0B0h], 0
    3.74 +			 * Win:		mov     byte ptr [esi+0B0h], 0
    3.75 +			 *
    3.76 +			 * L4D2: This has been moved into CBaseClient::UpdateUserSettings(), rest of the details are still relevant.
    3.77 +			 */
    3.78 +			"InfoChanged"
    3.79 +			{
    3.80 +				"windows"	"164"
    3.81 +				"linux"		"164"
    3.82 +				"mac"		"164"
    3.83 +			}
    3.84 +		}
    3.85 +	}
    3.86 +	
    3.87  	"nucleardawn"
    3.88  	{		
    3.89  		"Offsets"
    3.90  		{
    3.91  			"GiveNamedItem"
    3.92  			{
    3.93 -				"windows"	"442"
    3.94 -				"linux"		"443"
    3.95 -				"mac"		"443"
    3.96 +				"windows"	"443"
    3.97 +				"linux"		"444"
    3.98 +				"mac"		"444"
    3.99  			}
   3.100  			"RemovePlayerItem"
   3.101  			{
   3.102 -				"windows"	"300"
   3.103 -				"linux"		"301"
   3.104 -				"mac"		"301"
   3.105 +				"windows"	"301"
   3.106 +				"linux"		"302"
   3.107 +				"mac"		"302"
   3.108  			}
   3.109  			"Weapon_GetSlot"
   3.110  			{
   3.111 -				"windows"	"298"
   3.112 -				"linux"		"299"
   3.113 -				"mac"		"299"
   3.114 +				"windows"	"299"
   3.115 +				"linux"		"300"
   3.116 +				"mac"		"300"
   3.117  			}
   3.118  			"Ignite"
   3.119  			{
   3.120 -				"windows"	"233"
   3.121 -				"linux"		"234"
   3.122 -				"mac"		"234"
   3.123 +				"windows"	"234"
   3.124 +				"linux"		"235"
   3.125 +				"mac"		"235"
   3.126  			}
   3.127  			"Extinguish"
   3.128  			{
   3.129 -				"windows"	"236"
   3.130 -				"linux"		"237"
   3.131 -				"mac"		"237"
   3.132 +				"windows"	"237"
   3.133 +				"linux"		"238"
   3.134 +				"mac"		"238"
   3.135  			}
   3.136  			"Teleport"
   3.137  			{
   3.138 @@ -149,9 +184,9 @@
   3.139  			}
   3.140  			"CommitSuicide"
   3.141  			{
   3.142 -				"windows"	"487"
   3.143 -				"linux"		"487"
   3.144 -				"mac"		"487"
   3.145 +				"windows"	"488"
   3.146 +				"linux"		"488"
   3.147 +				"mac"		"488"
   3.148  			}
   3.149  			"GetVelocity"
   3.150  			{
   3.151 @@ -179,9 +214,9 @@
   3.152  			}
   3.153  			"WeaponEquip"
   3.154  			{
   3.155 -				"windows"	"291"
   3.156 -				"linux"		"292"
   3.157 -				"mac"		"292"
   3.158 +				"windows"	"292"
   3.159 +				"linux"		"293"
   3.160 +				"mac"		"293"
   3.161  			}
   3.162  			"Activate"
   3.163  			{
   3.164 @@ -191,9 +226,9 @@
   3.165  			}
   3.166  			"PlayerRunCmd"
   3.167  			{
   3.168 -				"windows"	"465"
   3.169 -				"linux"		"466"
   3.170 -				"mac"		"466"
   3.171 +				"windows"	"466"
   3.172 +				"linux"		"467"
   3.173 +				"mac"		"467"
   3.174  			}
   3.175  		}
   3.176  		
   3.177 @@ -207,7 +242,7 @@
   3.178  			"FireOutput"
   3.179  			{
   3.180  				"library"	"server"
   3.181 -				"windows"	"\x81\x2A\x2A\x2A\x2A\x2A\x53\x55\x56\x8B\x2A\x2A\x85"
   3.182 +				"windows"	"\x55\x8B\xEC\x83\xEC\x14\xD9\x45\x10\x8B\x45\x0C\x56\x8B"
   3.183  				"linux"		"@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
   3.184  				"mac"		"@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
   3.185  			}