Raised This Month: $ Target: $400
 0% 

[ORPHEU] Efficiency Help!!!!!!!!!


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
asur
Member
Join Date: Dec 2014
Old 12-31-2015 , 00:49   [ORPHEU] Efficiency Help!!!!!!!!!
Reply With Quote #1

Well guys I have silly question to ask about orpheu as I started playing with it nd i know the basics of orpheu concept but still some doubts are there .

Well suppose I want to block "chooseteam" command.
It can be done in 2 ways as following :

1. register_clcmd()
PHP Code:
register_clcmd"chooseteam""Hook_chooseteam")

public 
Hook_chooseteam(id)
     return 
PLUGIN_HANDLED 
2. Orpheu
PHP Code:
public plugin_init()
    
OrpheuRegisterHookOrpheuGetFunction("HandleMenu_ChooseTeam"), "HandleMenuTeam" )

public 
HandleMenuTeam(idmenu_choose)
    return 
OrpheuSupercede 
PHP Code:
{
    
"name"      "HandleMenu_ChooseTeam",
    
"library"   "mod",
    
"arguments" :
    [
        {
            
"type"  "CBasePlayer *"
        
},
        {
            
"type"  "int"
        
}
    ],
    
"identifiers":
    [
        {
            
"os"    "windows",
            
"mod"   "cstrike",
            
"value" : [0x83,0xEC,"*",0x8B,0x0D,"*","*","*","*",0x53,0x55,0x56,0x8B,0x74,0x24]
        },
        {
            
"os"    "linux",
            
"mod"   "cstrike",
            
"value" "_Z21HandleMenu_ChooseTeamP11CBasePlayeri"
        
}
    ]

My question is which of the 2 ways will be faster?
As my prediction is that orpheu will be faster as it is directly hooking the function but still if any1 can guide me please.
asur is offline
 



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 09:31.


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