gamedata/sdktools.games/engine.darkm.txt
author Fyren <fyrenmoo@gmail.com>
Tue Apr 07 09:59:21 2009 -0700 (2009-04-07)
changeset 2690 e3906d051a3b
parent 2583 d3b2571c378b
child 2746 8d68569b9648
permissions -rw-r--r--
Add a warning to not edit SM's gamedata files; switched to UNIX line endings (bug 3728, r=dvander)
     1 /**
     2  * Do not edit this file.  Any changes will be overwritten by the gamedata
     3  * updater or by upgrading your SourceMod install.
     4  *
     5  * To override data in this file, create a subdirectory named "custom" and
     6  * place your own gamedata file(s) inside of it.  Such files will be parsed
     7  * after SM's own.
     8  *
     9  * For more information, see http://wiki.alliedmods.net/Gamedata_Updating_(SourceMod)
    10  */
    11 
    12 "Games"
    13 {
    14 	/* Sounds */
    15 	"#default"
    16 	{
    17 		"Keys"
    18 		{
    19 			"SlapSoundCount"	"3"
    20 			"SlapSound1"		"default/player/sword_on_flesh_std01.wav"
    21 			"SlapSound2"		"default/player/sword_on_flesh_std05.wav"
    22 			"SlapSound3"		"default/player/bone_breaking03.wav"
    23 		}
    24 	}
    25 	
    26 	/* Properties */
    27 	"#default"
    28 	{
    29 		"Offsets"
    30 		{
    31 			"m_iHealth"
    32 			{
    33 				"class"			"CBasePlayer"
    34 				"prop"			"m_fHealth"
    35 			}
    36 		}
    37 	}
    38 	
    39 	/* General Temp Entities */
    40 	"#default"
    41 	{
    42 		"#supported"
    43 		{
    44 			"game"		"!Might and Magic Multiplayer"
    45 		}
    46 
    47 		"Offsets"
    48 		{
    49 			/* Offset into CBaseTempEntity constructor */
    50 			"s_pTempEntities"
    51 			{
    52 				"windows"	"17"
    53 			}
    54 			"GetTEName"
    55 			{
    56 				"windows"	"4"
    57 			}
    58 			"GetTENext"
    59 			{
    60 				"windows"	"8"
    61 			}
    62 			"TE_GetServerClass"
    63 			{
    64 				"windows"	"0"
    65 			}
    66 		}
    67 
    68 		"Signatures"
    69 		{
    70 			"CBaseTempEntity"
    71 			{
    72 				"library"	"server"
    73 				"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"
    74 			}
    75 		}
    76 	}
    77 	
    78 	/* Create Entity Signatures */
    79 	"#default"
    80 	{
    81 		"#supported"
    82 		{
    83 			"game"		"!Might and Magic Multiplayer"
    84 		}
    85 
    86 		"Signatures"
    87 		{
    88 			"DispatchSpawn"
    89 			{
    90 				"library"	"server"
    91 				"windows"	"\x53\x56\x8B\x74\x24\x0C\x85\xF6\x57\x0F\x84\x2A\x2A\x2A\x2A\x8B\x1D\x2A\x2A\x2A\x2A\x8B\x03\x8B\xCB\xFF\x50\x60\x8B\x16"
    92 			}
    93 			"CreateEntityByName"
    94 			{
    95 				"library"	"server"
    96 				"windows"	"\x56\x8B\x74\x24\x0C\x83\xFE\xFF\x57\x8B\x7C\x24\x0C\x74\x25\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x56\xFF\x50\x2A\x85\xC0"
    97 			}
    98 		}
    99 	}
   100 
   101 	/* CGlobalEntityList */
   102 	"#default"
   103 	{
   104 		"#supported"
   105 		{
   106 			"game"		"!Might and Magic Multiplayer"
   107 		}
   108 		
   109 		"Offsets"
   110 		{
   111 			/* Offset into LevelShutdown */
   112 			"gEntList"
   113 			{
   114 				"windows"	"11"
   115 			}
   116 		}
   117 		
   118 		"Signatures"
   119 		{
   120 			"LevelShutdown"
   121 			{
   122 				"library"	"server"
   123 				"windows"	"\xE8\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\xB9\x2A\x2A\x2A\x2A\xE8\x2A\x2A\x2A\x2A\xE8"
   124 			}
   125 
   126 			/* Functions in CGlobalEntityList */
   127 			"FindEntityByClassname"
   128 			{
   129 				"library"	"server"
   130 				"windows"	"\x53\x55\x56\x8B\xF1\x8B\x4C\x24\x10\x85\xC9\x57\x74\x18\x8B\x01\xFF\x50\x08\x8B\x08\x81\xE1\xFF\x0F\x00\x00\x83\xC1\x01\xC1\xE1\x04\x8B\x3C\x31\xEB\x06\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x3A\x8B\x5C\x24\x18\x8B\x2D\x2A\x2A\x2A\x2A\x8D"
   131 			}
   132 		}
   133 	}
   134 
   135 	/* General GameRules */
   136 	"#default"
   137 	{
   138 		"#supported"
   139 		{
   140 			"game"		"!Might and Magic Multiplayer"
   141 		}
   142 		
   143 		"Offsets"
   144 		{
   145 			/* Offset into CreateGameRulesObject */
   146 			"g_pGameRules"
   147 			{
   148 				"windows"	"2"
   149 			}
   150 		}
   151 		
   152 		"Signatures"
   153 		{
   154 			/* This signature sometimes has multiple matches, but this
   155 			 * does not matter as g_pGameRules is involved in all of them.
   156 			 * The same g_pGameRules offset applies to each match.
   157 			 *
   158 			 * Sometimes this block of bytes is at the beginning of the static
   159 			 * CreateGameRulesObject function and sometimes it is in the middle
   160 			 * of an entirely different function. This depends on the game.
   161 			 */
   162 			"CreateGameRulesObject"
   163 			{
   164 				"library"	"server"
   165 				"windows"	"\x8B\x0D\x2A\x2A\x2A\x2A\x85\xC9\x74\x2A\x8B\x01\x6A\x01\xFF\x50"
   166 			}
   167 		}
   168 	}
   169 
   170 	/* IServer interface pointer */
   171 	"#default"
   172 	{
   173 		"Keys"
   174 		{
   175 			/* Signature for the beginning of IVEngineServer::CreateFakeClient.
   176 			 *
   177 			 * The engine binary is not actually scanned in order to look for
   178 			 * this. SourceHook is used to used to determine the address of the
   179 			 * function and this signature is used to verify that it contains
   180 			 * the expected code. A pointer to sv (IServer interface) is used
   181 			 * here.
   182 			 */
   183 			"CreateFakeClient_Windows"	"\x8B\x44\x24\x2A\x50\xB9\x2A\x2A\x2A\x2A\xE8"
   184 		}
   185 		
   186 		"Offsets"
   187 		{
   188 			/* Offset into IVEngineServer::CreateFakeClient */
   189 			"sv"
   190 			{
   191 				"windows"	"6"
   192 			}
   193 		}
   194 	}
   195 	
   196 	/* EntityFactoryDictionary function */
   197 	"#default"
   198 	{
   199 		"Signatures"
   200 		{
   201 			"EntityFactory"
   202 			{
   203 				"library"	"server"
   204 				"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"
   205 			}
   206 		}
   207 	}
   208 
   209 	/* CBaseEntityOutput::FireOutput */
   210 	"#default"
   211 	{
   212 		"#supported"
   213 		{
   214 			"game"		"!Might and Magic Multiplayer"
   215 		}
   216 		"Signatures"
   217 		{
   218 			"FireOutput"
   219 			{
   220 				"library"	"server"
   221 				"windows"	"\x83\xEC\x1C\x53\x55\x56\x8B\x71\x14"
   222 				"linux"		"@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
   223 			}
   224 		}
   225 		"Offsets"
   226 		{
   227 			"FireOutputBackup"
   228 			{
   229 				"windows"	"6"
   230 			}
   231 		}
   232 	}
   233 	
   234 	/* SetUserInfo data */
   235 	"#default"
   236 	{
   237 		"Offsets"
   238 		{
   239 			/**
   240 			 * CBaseClient::SetUserCVar(char  const*,char  const*);
   241 			 * Linux offset straight from VTable dump.
   242 			 * Windows offset is crazy. Found the windows 'SetName' function using string "(%d)%-0.*s"
   243 			 * Cross referenced back to the vtable and counted manually (SetUserCvar is 1 higher, offsets start from 1)
   244 			 */
   245 			"SetUserCvar"
   246 			{
   247 				"windows"	"17"
   248 			}
   249 
   250 			"UpdateUserSettings"
   251 			{
   252 				"windows"	"7"
   253 			}
   254 		}
   255 	}
   256 	
   257 	/* Dark Messiah */
   258 	"!Might and Magic Multiplayer"
   259 	{
   260 		"Offsets"
   261 		{
   262 			"GiveNamedItem"
   263 			{
   264 				"windows"	"309"
   265 			}
   266 			"RemovePlayerItem"
   267 			{
   268 				"windows"	"210"
   269 			}
   270 			"Weapon_GetSlot"
   271 			{
   272 				"windows"	"208"
   273 			}
   274 			"Ignite"
   275 			{
   276 				"windows"	"172"
   277 			}
   278 			"Extinguish"
   279 			{
   280 				"windows"	"173"
   281 			}
   282 			"Teleport"
   283 			{
   284 				"windows"	"92"
   285 			}
   286 			"GetVelocity"
   287 			{
   288 				"windows"	"115"
   289 			}
   290 			"EyeAngles"
   291 			{
   292 				"windows"	"107"
   293 			}
   294 			"AcceptInput"
   295 			{
   296 				"windows"	"34"
   297 			}
   298 			"DispatchKeyValue"
   299 			{
   300 				"windows"	"30"
   301 			}
   302 			"DispatchKeyValueFloat"
   303 			{
   304 				"windows"	"29"
   305 			}
   306 			"DispatchKeyValueVector"
   307 			{
   308 				"windows"	"28"
   309 			}
   310 			"SetEntityModel"
   311 			{
   312 				"windows"	"25"
   313 			}
   314 			"WeaponEquip"
   315 			{
   316 				"windows"	"202"
   317 			}
   318 			"Activate"
   319 			{
   320 				"windows"	"32"
   321 			}
   322 		}
   323 		
   324 		"Signatures"
   325 		{
   326 			"CommitSuicide"
   327 			{
   328 				"library"	"server"
   329 				"windows"	"\x83\xEC\x44\x56\x8B\xF1\x8B\x8E\x2A\x00\x00\x00\x85\xC9"
   330 			}
   331 		}
   332 	}
   333 }