Raised This Month: $127 Target: $400
 31% 

Orpheu: Searching for functions in libraries


Post New Thread Reply   
 
Thread Tools Display Modes
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 07-27-2010 , 13:26   Re: Orpheu: Searching for functions in libraries
Reply With Quote #21

I remember Quim saying "Vector" (without *) can't work. By the way, about your first example, you can't hook client-side functions with a server-side plugin...

What's wrong with the VEN's method ?
__________________
Working on : CS Weapon Mod (72%) , MonsterAI (PAUSED),

Arkshine is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 03-10-2011 , 14:32   Re: Orpheu: Searching for functions in libraries
Reply With Quote #22

I've tried to search for InstallGameRules too, and the offset matches with yours,
but mine doesn't have the "exec game.cfg\n" string in it.
Did i do something wrong ?

Code:
//----- (000B3C10) --------------------------------------------------------
int __cdecl InstallGameRules()
{
  int result; // [email protected]
  int v1; // [email protected]
  int v3; // [email protected]
  int v4; // [email protected]

  v1 = *(_DWORD *)((char *)loc_1326EB + 746809);
  (*(int (__cdecl **)(char *))(v1 + 156))((char *)loc_1326EB + 512685);
  (*(int (**)(void))(v1 + 160))();
  _EAX = **(_DWORD **)((char *)loc_1326EB + 744429);
  __asm
  {
    fldz
    fld     dword ptr [eax+14h]
    fucompp
    fnstsw  ax
  }
  if ( BYTE1(_EAX) & 0x44 ^ 0x40 )
  {
    v4 = __builtin_new(0x2C4u);
    result = __18CHalfLifeMultiplay(v4);
  }
  else
  {
    v3 = __builtin_new(0x2D8u);
    result = __17CHalfLifeTraining(v3);
  }
  return result;
}
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 03-10-2011 , 14:37   Re: Orpheu: Searching for functions in libraries
Reply With Quote #23

Don't know. What IDA version you're using ? What you show me happen when it fails to decompile properly. Though you don't need to decompile, the string should appear in the IDA View tab.
__________________
Working on : CS Weapon Mod (72%) , MonsterAI (PAUSED),

Arkshine is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 03-10-2011 , 14:40   Re: Orpheu: Searching for functions in libraries
Reply With Quote #24

I'm using version 5.2.0.908.
I've tried to decompile it several times, but always end up with that code.
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 03-10-2011 , 14:42   Re: Orpheu: Searching for functions in libraries
Reply With Quote #25

You may try to open the binary with different options or try a newer version. (Like 5.5, what I'm using). You can also try to open the CZ binary or the CS binary (with hlbeta update), it's compiled differently, so there is a chance IDA handles it differently too.
__________________
Working on : CS Weapon Mod (72%) , MonsterAI (PAUSED),

Arkshine is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 03-10-2011 , 15:23   Re: Orpheu: Searching for functions in libraries
Reply With Quote #26

I've downloaded version 5.5 and did everything over.
Now the function matches, and i also saw the string in the other function from the signature tutorial.
Thanks
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 03-10-2011 , 15:34   Re: Orpheu: Searching for functions in libraries
Reply With Quote #27

You are a pro now.
__________________
Working on : CS Weapon Mod (72%) , MonsterAI (PAUSED),

Arkshine is offline
meTaLiCroSS
Gaze Upon My Hat
Join Date: Feb 2009
Location: Viņa del Mar, Chile
Old 03-11-2011 , 13:03   Re: Orpheu: Searching for functions in libraries
Reply With Quote #28

Quote:
Originally Posted by Arkshine View Post
You are a pro now.
2012
__________________
Quote:
Originally Posted by joropito View Post
You're right Metalicross
meTaLiCroSS is offline
hlstriker
Green Gaben
Join Date: Mar 2006
Location: OH-IO!
Old 04-07-2011 , 21:14   Re: Orpheu: Searching for functions in libraries
Reply With Quote #29

I decompiled the .so for TFC and I'm trying to understand a function.

In the code below how would I know that victim + 32 is the players X velocity? I'm guessing 32 is an offset but where would I look to figure out what this offset belongs to?
PHP Code:
velocity1 = *(float *)(*(_DWORD *)victim 32) * 0.3300000131130219;
velocity2 = *(float *)(*(_DWORD *)victim 36) * 0.3300000131130219;
velocity3 0.3300000131130219 * *(float *)(*(_DWORD *)victim 40); 
In this part of the code I'm guessing it's a function being called but I'm not sure what's going on. Can someone explain to me?
PHP Code:
(*(void (__cdecl **)(intint))(*(_DWORD *)(victim 1136) + 260))(victimconcEnt); 
I mainly want to figure out how to find the function/variable that belongs to an offset.
hlstriker is offline
Arkshine
AMX Mod X Plugin Approver
Join Date: Oct 2005
Old 04-08-2011 , 00:16   Re: Orpheu: Searching for functions in libraries
Reply With Quote #30

- Yes, an offset, but probably more related to entvars_s structure, so it should be a pev->something.

- Probably a virtul call. To know what function it is, I guess you need to find the vtable of the related class. (CBasePlayer? CBasePlayerItem ? etc..). To get the index from this virtual call, it should be : 260/4 - 2 = 63. So the 63th in the vtable list should be your function. (Like hamdata.ini).

For both, what functions ? I will take a look.
__________________
Working on : CS Weapon Mod (72%) , MonsterAI (PAUSED),

Arkshine is offline
Reply


Thread Tools
Display Modes

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 23:08.


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