Raised This Month: $51 Target: $400
 12% 

My server crashes when function is called with orpheu


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
shinoda
Spanish Moderator
Join Date: Nov 2009
Location: ag_crossfire
Old 12-06-2011 , 13:28   My server crashes when function is called with orpheu
Reply With Quote #1

I'm hooking StartObserver function, but my server crashes when is called.

My code:
PHP Code:
#include <amxmodx>
#include <orpheu>

public plugin_init()
{
    
OrpheuRegisterHookOrpheuGetFunction("StartObserver""CBasePlayer"), "OnStartObserver"OrpheuHookPre )
}

public 
OnStartObserver( const id, const Float:vecOrigin[3], const Float:vecViewAngle[3] )
{
    
server_print"Testing" )

Sig in orpheu/functions/CBasePlayer
Code:
{
	"name"      : "StartObserver",
	"class"     : "CBasePlayer",
	"library"   : "mod",
	"arguments" :
	[
		{
			"type" : "Vector",
			"type" : "Vector"
		}
	],
	"return" :
	{
		"type" : "int"
	},
	"identifiers" :
	[
		{
			"os"    : "windows",
			"mod"   : "valve",
			"value" : [0x53,0x56,0x8B,0xF1,0x57,0x33,"*",0x8B,0x46,"*",0x57,0x83,0xC0,"*",0x50,0x6A]
		},
		{
			"os"    : "linux",
			"mod"   : "valve",
			"value" : "StartObserver__11CBasePlayerG6VectorT1"
		}
	]
}
Output
Code:
Orpheu functions search started.

	Parsing functions started.
		Parsing file "InstallGameRules" started
				Function is updated
		Parsing file "InstallGameRules" ended
		Parsing file "InstallGameRules_tfc" started
				Argument type "char *" validated
				Return type "CHalfLifeMultiplay *" validated
		Parsing file "InstallGameRules_tfc" ended
		Parsing file "FireTargets" started
				Function is updated
		Parsing file "FireTargets" ended
		Parsing folder "CRuleEntity" started
			Parsing file "CanFireForActivator" started
				Function is updated
			Parsing file "CanFireForActivator" ended
		Parsing folder "CRuleEntity" ended
		Parsing folder "CGamePlayerTeam" started
			Parsing file "TargetTeamName" started
				Function is updated
			Parsing file "TargetTeamName" ended
		Parsing folder "CGamePlayerTeam" ended
		Parsing folder "CBasePlayer" started
			Parsing file "StartObserver" started
				Function is updated
			Parsing file "StartObserver" ended
		Parsing folder "CBasePlayer" ended
	Parsing functions ended.

Orpheu functions search ended.
__________________
Oh hell no this shit is awesome !!!

Last edited by shinoda; 12-06-2011 at 20:49.
shinoda is offline
Send a message via MSN to shinoda Send a message via Skype™ to shinoda
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 12-06-2011 , 15:39   Re: My server crashes when function is called with orpheu
Reply With Quote #2

You can't. Vector -alone- is not supported.
__________________
Arkshine is offline
shinoda
Spanish Moderator
Join Date: Nov 2009
Location: ag_crossfire
Old 12-06-2011 , 20:52   Re: My server crashes when function is called with orpheu
Reply With Quote #3

Oh, I forgot this list:
Code:
    "bool"
    "byte"
    "long"
    "CBaseEntity *"
    "char *"
    "edict_s *"
    "float"
    "Vector *"
    "CMBaseMonster *"
    "char"
    "short"
    "entvars_s *"
Thanks Arkshine.
__________________
Oh hell no this shit is awesome !!!
shinoda is offline
Send a message via MSN to shinoda Send a message via Skype™ to shinoda
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 12:37.


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