I just found some time, I am beginning to learn to read through ASM and decipher this. I am having some particular trouble with floating point operations. I just can't figure out how to introduce the values I want into them (directly editing the assembly in memory, no injection yet)
Case in point, this code is used to calculate COF/bullet trajectory: I am just having a hard time understanding it.
This is all around [planetside+008fb150]
PHP Code:
fld dword ptr [eax+0c]
fdiv dword ptr [ebp-08]
fmul dword ptr [00b7f440] : 447A0000
fsubr dword ptr [ebp-0c]
fstp dword ptr [ebp-08]
fld dword ptr [ebp-08]
fcomp dword ptr [ebp-04]
fnstsw ax
test ah,05
jp 008fb160
mov edx,[ebp-04]
mov [ebp-08],edx
fld dword ptr [ebp-08]
fcomp dword ptr [ebp-10]
fnstsw ax
test ah,41
jne 008fb173
mov eax,[ebp-10]
mov [ebp-08],eax
mov ecx,[ebp-08]
push ecx
mov ecx,edi
call 00908320
pop edi
pop esi
mov esp,ebp
pop ebp
I am just needing some insight as to how this entire little section operates. I know it loads the current COF value from [eax+0c], and then does a few operations and stores it. How would I go about manipulating these operations to introduce my own COF values?