Raised This Month: $32 Target: $400
 8% 

Gamedata again


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Leonardo
Veteran Member
Join Date: Feb 2010
Location: 90's
Old 02-22-2015 , 09:10   Gamedata again
Reply With Quote #1

Hello!
Today I'm trying to get netprops from Double Action: Boogaloo's (Steam version) gamerules entity (sdk_gamerules, CSDKGameRulesProxy).
I did create a /addons/sourcemod/gamedata/sdktools.game/custom/game.dab.txt with following data:
Code:
"Games"
{
	/* DA:B */
	"dab"
	{
		"Keys"
		{
			"GameRulesProxy"	"CSDKGameRulesProxy"
		}
	}
}
But calling GameRules_GetProp* says Native "GameRules_GetProp" reported: Gamerules lookup failed.
Where did it go so wrong?
__________________
Leonardo is offline
psychonic

BAFFLED
Join Date: May 2008
Old 02-22-2015 , 10:36   Re: Gamedata again
Reply With Quote #2

Also add "GameRulesDataTable" "sdk_gamerules" to the Keys there (or the old-style gamerules gamedata with signature+offset on Windows and g_pGameRules symbol on Linux/Mac).
psychonic is offline
Leonardo
Veteran Member
Join Date: Feb 2010
Location: 90's
Old 02-22-2015 , 11:27   Re: Gamedata again
Reply With Quote #3

Quote:
Originally Posted by psychonic View Post
Also add "GameRulesDataTable" "sdk_gamerules" to the Keys there (or the old-style gamerules gamedata with signature+offset on Windows and g_pGameRules symbol on Linux/Mac).
That was close, but, sadly, didn't work.
Code:
"Games"
{
	/* DA:B */
	"dab"
	{
		"Offsets"
		{
			/* Offset into CreateGameRulesObject */
			"g_pGameRules"
			{
				"windows"	"2"
				"linux"		"1"
			}
		}
		"Signatures"
		{
			/* This signature sometimes has multiple matches, but this
			 * does not matter as g_pGameRules is involved in all of them.
			 * The same g_pGameRules offset applies to each match.
			 *
			 * Sometimes this block of bytes is at the beginning of the static
			 * CreateGameRulesObject function and sometimes it is in the middle
			 * of an entirely different function. This depends on the game.
			 */
			"CreateGameRulesObject"
			{
				"library"	"server"
				"windows"	"\x8B\x0D\x2A\x2A\x2A\x2A\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2A\x6A\x01\xFF\xD2"
				"linux"		"\xA1\x2A\x2A\x2A\x2A\x8B\x5D\x08\x85\xC0\x74\x08\x8B\x10\x89"
			}
			
			/* Functions in CGlobalEntityList */
			"FindEntityByClassname"
			{
				"library"	"server"
				"windows"	"\x55\x8B\xEC\x53\x56\x8B\xF1\x8B\x4D\x2A\x57\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2A\xFF\xD2\x8B\x00\x25\xFF\x0F\x00\x00\x40\x03\xC0\x8B\x3C\xC6\xEB\x2A\x8B"
				"linux"		"\x55\x89\xE5\x57\x56\x53\x83\xEC\x1C\x8B\x45\x0C\x8B\x5D\x08\x8B\x7D\x10\x85\xC0\x74\x2A\x8B\x10\x89\x04\x24\xFF\x52\x0C\x8B\x00\x25\xFF\x0F\x00\x00\xC1\xE0\x04\x8B\x5C\x03\x10\xEB\x2A\x66\x90\x89\x7C\x24\x04"
			}
		}
		"Keys"
		{
			"GameRulesProxy"	"CSDKGameRulesProxy"
			"GameRulesDataTable"	"sdk_gamerules"
		}
	}
}
Code:
L 02/22/2015 - 19:24:27: [SM] Native "GameRules_GetProp" reported: Gamerules lookup failed.
SourceMod ver.1.6.2
(Meta) Interface ServerGameDLL008
(Meta) Source SDK 2013 (2013)

Edit:
oh wait guess it should be sdk_gamerules_data instead. I'll check it.

Edit2:
Nope, same result.
Missing error log line (on map start):
Code:
L 02/22/2015 - 19:24:24: [SDKTOOLS] "FindEntityByClassname" not supported by this mod, falling back to IServerTools method.
Like SM ignores custom folder.

Last edited by Leonardo; 02-22-2015 at 14:04.
Leonardo is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 20:41.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode