Reversing Silkroad Player Class

05/30/2012 10:34 theonly112#1
First off, im a total reversing noob. But here is what i've got so far.

Code:
class CPlayer
{
public:
char _0x0000[56];
	DWORD UpdateCount; //0x0038 
	DWORD TickCount; //0x003C 
char _0x0040[60];
	BYTE XSector; //0x007C 
	BYTE YSector; //0x007D 
char _0x007E[2];
	D3DVECTOR3 CurrentPos; //0x0080 
char _0x008C[4];
	D3DVECTOR3 CurrentPos2; //0x0090 
char _0x009C[28];
	__int32 FrameCounter; //0x00B8 
char _0x00BC[20];
	float CamDistance; //0x00D0 
char _0x00D4[40];
	BYTE unkXSector; //0x00FC 
	BYTE unkYSector; //0x00FD 
	WORD unk; //0x00FE 
	D3DVECTOR3 unkPosition; //0x0100 
char _0x010C[836];
	DWORD CurrentHP; //0x0450 
	DWORD CurrentMP; //0x0454 
	DWORD MaxHP; //0x0458 
	DWORD MaxMP; //0x045C 
	DWORD CurrentHP2; //0x0460 
char _0x0464[260];
	__int32 isBusy; //0x0568 
char _0x056C[256];
	float Walkspeed; //0x066C 
	float RunSpeed; //0x0670 
char _0x0674[16];
	BYTE TargetXSector; //0x0684 
	BYTE TargetYSector; //0x0685 
char _0x0686[2];
	D3DVECTOR3 TargetPos; //0x0688 
char _0x0694[12];
	BYTE TargetXSector2; //0x06A0 
	BYTE TargetYSector2; //0x06A1 
char _0x06A2[2];
	D3DVECTOR3 TargetPos2; //0x06A4 
char _0x06B0[12];
	BYTE XSector2; //0x06BC 
	__int8 YSector; //0x06BD 
char _0x06BE[2];
	D3DVECTOR3 Position; //0x06C0 
char _0x06CC[28];
	BYTE WalkingType; //0x06E8 
char _0x06E9[3];
	__int32 isWalking3; //0x06EC 
char _0x06F0[36];
	BYTE isWalking; //0x0714 
char _0x0715[347];
	DWORD CurrentExp; //0x0870 
char _0x0874[12];
	__int32 CurrentSP; //0x0880 
	WORD StatPoints; //0x0884 
	BYTE BerserkPoints; //0x0886 
	BYTE BerserkPoints2; //0x0887 
char _0x0888[120];

};//Size=0x0900
Has anybody been working on something similar?
06/02/2012 11:05 tarekwiz#2
can i ask you a question?
how did you find these opcodes and thier functions?
06/02/2012 12:20 Th3K1nG#3
Quote:
Originally Posted by tarekwiz View Post
can i ask you a question?
how did you find these opcodes and thier functions?
There some tools for it ... Packet Analyzer, OllyDbg ,Cheat Engine whatever?


Quote:
Originally Posted by theonly112 View Post
First off, im a total reversing noob. But here is what i've got so far.

Code:
class CPlayer
{
public:
char _0x0000[56];
	DWORD UpdateCount; //0x0038 
	DWORD TickCount; //0x003C 
char _0x0040[60];
	BYTE XSector; //0x007C 
	BYTE YSector; //0x007D 
char _0x007E[2];
	D3DVECTOR3 CurrentPos; //0x0080 
char _0x008C[4];
	D3DVECTOR3 CurrentPos2; //0x0090 
char _0x009C[28];
	__int32 FrameCounter; //0x00B8 
char _0x00BC[20];
	float CamDistance; //0x00D0 
char _0x00D4[40];
	BYTE unkXSector; //0x00FC 
	BYTE unkYSector; //0x00FD 
	WORD unk; //0x00FE 
	D3DVECTOR3 unkPosition; //0x0100 
char _0x010C[836];
	DWORD CurrentHP; //0x0450 
	DWORD CurrentMP; //0x0454 
	DWORD MaxHP; //0x0458 
	DWORD MaxMP; //0x045C 
	DWORD CurrentHP2; //0x0460 
char _0x0464[260];
	__int32 isBusy; //0x0568 
char _0x056C[256];
	float Walkspeed; //0x066C 
	float RunSpeed; //0x0670 
char _0x0674[16];
	BYTE TargetXSector; //0x0684 
	BYTE TargetYSector; //0x0685 
char _0x0686[2];
	D3DVECTOR3 TargetPos; //0x0688 
char _0x0694[12];
	BYTE TargetXSector2; //0x06A0 
	BYTE TargetYSector2; //0x06A1 
char _0x06A2[2];
	D3DVECTOR3 TargetPos2; //0x06A4 
char _0x06B0[12];
	BYTE XSector2; //0x06BC 
	__int8 YSector; //0x06BD 
char _0x06BE[2];
	D3DVECTOR3 Position; //0x06C0 
char _0x06CC[28];
	BYTE WalkingType; //0x06E8 
char _0x06E9[3];
	__int32 isWalking3; //0x06EC 
char _0x06F0[36];
	BYTE isWalking; //0x0714 
char _0x0715[347];
	DWORD CurrentExp; //0x0870 
char _0x0874[12];
	__int32 CurrentSP; //0x0880 
	WORD StatPoints; //0x0884 
	BYTE BerserkPoints; //0x0886 
	BYTE BerserkPoints2; //0x0887 
char _0x0888[120];

};//Size=0x0900
Has anybody been working on something similar?
I guess this isn't a good method ... you should look at some bot sources
06/02/2012 23:18 theonly112#4
@Th3K1nG you don't seem to understand what I posted.
This is not the structure of some packet. I'm talking about the Player Class/Structe that's being used within the client itself.

@tarekwiz
I used olly and ReClass. you can find reclass on gamedeception.net