Moderator: MacroQuest Developers
Code: Select all
.text:0045EFE5 EQPlayer__IsRoleplaying
.text:0045EFE5 ; EQPlayer__SetNameSpriteTint+150p ...
.text:0045EFE5 mov eax, [ecx+18Ch]
.text:0045EFEB shr eax, 1
.text:0045EFED and eax, 1
.text:0045EFF0 retn
.text:0045EFF0 EQPlayer__IsRoleplaying endp
Code: Select all
.text:0046137F EQPlayer__SetAfk
.text:0046137F
.text:0046137F arg_0 = dword ptr 4
.text:0046137F
.text:0046137F mov eax, [esp+arg_0]
.text:00461383 mov [ecx+1BCh], eax
.text:00461389 retn 4
Code: Select all
EQPlayer EQPlayer::SetAfk(EQPlayer *player)
{
player->afk = true;
return player;
}
[ecx+18Ch] will always correspond to this->Roleplaying (if it's correct here) when ecx is equal to EQPlayer or whatever it is set to before this function is calledObviously, 'ecx+18Ch' is 'this->Roleplaying'. Therefore, can I assume that 18Ch is always 'roleplying' throughout this entire stack? Or, will it vary from function to function? (ie, I could rename it in my version?..)

Code: Select all
return ((this->BitFlag >> 1) & 0x1);
Code: Select all
void EQPlayer::SetAfk(DWORD dwValue)
{
this->afk = dwValue
return;
}
Is there a way to determine where "roleplaying" is in the struct based upon this information? 18Ch ...doesn't mean a lot to me really...[ecx+18Ch] will always correspond to this->Roleplaying (if it's correct here) when ecx is equal to EQPlayer or whatever it is set to before this function is called
Code: Select all
.text:0045F4F1 EQPlayer__SetArmorType proc near ; CODE XREF: UnPackNetPlayer+6Cp
.text:0045F4F1 ; EQPlayer__UpdateItemSlot+262p ...
.text:0045F4F1
.text:0045F4F1 arg_0 = dword ptr 4
.text:0045F4F1 arg_4 = dword ptr 8
.text:0045F4F1
.text:0045F4F1 mov eax, [esp+arg_0] ; public: void __thiscall EQPlayer::SetArmorType(int,int)
.text:0045F4F5 test eax, eax
.text:0045F4F7 jl short locret_45F509
.text:0045F4F9 cmp eax, 8
.text:0045F4FC jg short locret_45F509
.text:0045F4FE mov edx, [esp+arg_4]
.text:0045F502 mov [ecx+eax*4+0F0h], edx
.text:0045F509
.text:0045F509 locret_45F509: ; CODE XREF: EQPlayer__SetArmorType+6j
.text:0045F509 ; EQPlayer__SetArmorType+Bj
.text:0045F509 retn 8
.text:0045F509 EQPlayer__SetArmorType endp
Code: Select all
.text:0046137F EQPlayer__SetAfk
.text:0046137F
.text:0046137F arg_0 = dword ptr 4
.text:0046137F
.text:0046137F mov eax, [esp+arg_0]
.text:00461383 mov [ecx+1BCh], eax
.text:00461389 retn 4