Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- .text:00770F40 ; =============== S U B R O U T I N E =======================================
- .text:00770F40
- .text:00770F40 ; Attributes: bp-based frame
- .text:00770F40
- .text:00770F40 ; char __thiscall sub_770F40(void *this, int pSoldier)
- .text:00770F40 sub_770F40 proc near ; CODE XREF: sub_771840+A5p
- .text:00770F40
- .text:00770F40 var_10C = dword ptr -10Ch
- .text:00770F40 var_108 = dword ptr -108h
- .text:00770F40 var_104 = dword ptr -104h
- .text:00770F40 var_100 = dword ptr -100h
- .text:00770F40 var_FC = dword ptr -0FCh
- .text:00770F40 var_F8 = dword ptr -0F8h
- .text:00770F40 var_F4 = dword ptr -0F4h
- .text:00770F40 var_F0 = xmmword ptr -0F0h
- .text:00770F40 var_E0 = qword ptr -0E0h
- .text:00770F40 var_D8 = qword ptr -0D8h
- .text:00770F40 var_D0 = xmmword ptr -0D0h
- .text:00770F40 var_C0 = xmmword ptr -0C0h
- .text:00770F40 var_AC = dword ptr -0ACh
- .text:00770F40 var_A8 = dword ptr -0A8h
- .text:00770F40 var_A4 = dword ptr -0A4h
- .text:00770F40 var_A0 = dword ptr -0A0h
- .text:00770F40 var_9C = dword ptr -9Ch
- .text:00770F40 var_98 = dword ptr -98h
- .text:00770F40 var_94 = dword ptr -94h
- .text:00770F40 var_90 = byte ptr -90h
- .text:00770F40 var_80 = xmmword ptr -80h
- .text:00770F40 var_70 = xmmword ptr -70h
- .text:00770F40 var_60 = byte ptr -60h
- .text:00770F40 var_30 = xmmword ptr -30h
- .text:00770F40 var_20 = qword ptr -20h
- .text:00770F40 var_18 = qword ptr -18h
- .text:00770F40 var_10 = dword ptr -10h
- .text:00770F40 var_C = dword ptr -0Ch
- .text:00770F40 var_8 = dword ptr -8
- .text:00770F40 var_4 = dword ptr -4
- .text:00770F40 pSoldier = dword ptr 8
- .text:00770F40
- .text:00770F40 push ebp
- .text:00770F41 mov ebp, esp
- .text:00770F43 and esp, 0FFFFFFF0h
- .text:00770F46 sub esp, 114h
- .text:00770F4C push ebx
- .text:00770F4D push esi
- .text:00770F4E mov esi, ecx
- .text:00770F50 mov eax, [esi]
- .text:00770F52 mov edx, [eax+2Ch]
- .text:00770F55 push edi
- .text:00770F56 mov [esp+120h+var_F4], esi
- .text:00770F5A call edx
- .text:00770F5C test eax, eax
- .text:00770F5E jz short loc_770F6B
- .text:00770F60 add eax, 0FFFFFF10h
- .text:00770F65 mov [esp+120h+var_F8], eax
- .text:00770F69 jmp short loc_770F73
- .text:00770F6B ; ---------------------------------------------------------------------------
- .text:00770F6B
- .text:00770F6B loc_770F6B: ; CODE XREF: sub_770F40+1Ej
- .text:00770F6B mov [esp+120h+var_F8], 0
- .text:00770F73
- .text:00770F73 loc_770F73: ; CODE XREF: sub_770F40+29j
- .text:00770F73 mov ecx, esi
- .text:00770F75 call sub_11F4020
- .text:00770F7A mov edi, [ebp+pSoldier]
- .text:00770F7D mov ebx, eax
- .text:00770F7F mov eax, [edi+8]
- .text:00770F82 shr eax, 12h
- .text:00770F85 test al, 1
- .text:00770F87 mov eax, [edi+1Ch]
- .text:00770F8A mov [esp+120h+var_104], ebx
- .text:00770F8E jz short loc_770FA4
- .text:00770F90 movzx ecx, byte ptr [eax+6]
- .text:00770F94 lea ecx, [ecx+ecx*4]
- .text:00770F97 shl ecx, 4
- .text:00770F9A lea edx, [ecx+eax+10h]
- .text:00770F9E mov [esp+120h+var_FC], edx
- .text:00770FA2 jmp short loc_770FA8
- .text:00770FA4 ; ---------------------------------------------------------------------------
- .text:00770FA4
- .text:00770FA4 loc_770FA4: ; CODE XREF: sub_770F40+4Ej
- .text:00770FA4 mov [esp+120h+var_FC], eax
- .text:00770FA8
- .text:00770FA8 loc_770FA8: ; CODE XREF: sub_770F40+62j
- .text:00770FA8 mov eax, [esp+120h+var_F8]
- .text:00770FAC mov ecx, [eax+8]
- .text:00770FAF mov eax, [eax+1Ch]
- .text:00770FB2 shr ecx, 12h
- .text:00770FB5 test cl, 1
- .text:00770FB8 jz short loc_770FC8
- .text:00770FBA movzx ecx, byte ptr [eax+6]
- .text:00770FBE lea edx, [ecx+ecx*4]
- .text:00770FC1 shl edx, 4
- .text:00770FC4 lea eax, [edx+eax+10h]
- .text:00770FC8
- .text:00770FC8 loc_770FC8: ; CODE XREF: sub_770F40+78j
- .text:00770FC8 movaps xmm1, xmmword ptr [eax+30h]
- .text:00770FCC mov eax, [esp+120h+var_FC]
- .text:00770FD0 movaps xmm0, xmmword ptr [eax+30h]
- .text:00770FD4 subps xmm0, xmm1
- .text:00770FD7 movaps [esp+120h+var_F0], xmm0
- .text:00770FDC mulps xmm0, xmm0
- .text:00770FDF movaps xmm2, xmm0
- .text:00770FE2 movaps xmm1, xmm0
- .text:00770FE5 shufps xmm1, xmm0, 55h
- .text:00770FE9 shufps xmm2, xmm0, 0
- .text:00770FED shufps xmm0, xmm0, 0AAh
- .text:00770FF1 addps xmm1, xmm2
- .text:00770FF4 addps xmm1, xmm0
- .text:00770FF7 cvtss2sd xmm0, xmm1
- .text:00770FFB sqrtsd xmm0, xmm0
- .text:00770FFF cvtsd2ss xmm0, xmm0
- .text:00771003 movss [esp+120h+var_10C], xmm0
- .text:00771009 movss xmm0, dword ptr [ebx+78h]
- .text:0077100E mov ecx, esi
- .text:00771010 movss [esp+120h+var_100], xmm0
- .text:00771016 call sub_11F2870
- .text:0077101B movss xmm0, [esp+120h+var_100]
- .text:00771021 movaps xmm1, xmmword ptr [eax]
- .text:00771024 shufps xmm0, xmm0, 0
- .text:00771028 mulps xmm0, xmm1
- .text:0077102B mulps xmm0, xmm0
- .text:0077102E movaps xmm2, xmm0
- .text:00771031 shufps xmm2, xmm0, 0
- .text:00771035 movaps xmm1, xmm0
- .text:00771038 shufps xmm1, xmm0, 55h
- .text:0077103C addps xmm1, xmm2
- .text:0077103F shufps xmm0, xmm0, 0AAh
- .text:00771043 addps xmm1, xmm0
- .text:00771046 movss xmm0, [esp+120h+var_10C]
- .text:0077104C cvtss2sd xmm1, xmm1
- .text:00771050 sqrtsd xmm1, xmm1
- .text:00771054 cvtsd2ss xmm1, xmm1
- .text:00771058 cvtps2pd xmm2, xmm0
- .text:0077105B cvtss2sd xmm1, xmm1
- .text:0077105F comisd xmm2, xmm1
- .text:00771063 jbe short loc_771070
- .text:00771065 xor al, al
- .text:00771067 pop edi
- .text:00771068 pop esi
- .text:00771069 pop ebx
- .text:0077106A mov esp, ebp
- .text:0077106C pop ebp
- .text:0077106D retn 4
- .text:00771070 ; ---------------------------------------------------------------------------
- .text:00771070
- .text:00771070 loc_771070: ; CODE XREF: sub_770F40+123j
- .text:00771070 movaps xmm1, [esp+120h+var_F0]
- .text:00771075 mov ecx, dword_2380B58
- .text:0077107B shufps xmm0, xmm0, 0
- .text:0077107F divps xmm1, xmm0
- .text:00771082 movaps [esp+120h+var_F0], xmm1
- .text:00771087 mov edx, [ebx+84h]
- .text:0077108D mov esi, [ecx+14h]
- .text:00771090 lea ebx, [edi+0F0h]
- .text:00771096 mov ecx, ebx
- .text:00771098 mov [esp+120h+var_10C], edx
- .text:0077109C call sub_11E4E40
- .text:007710A1 push eax
- .text:007710A2 mov eax, [esp+124h+var_10C]
- .text:007710A6 push eax
- .text:007710A7 lea ecx, [esp+128h+var_10C]
- .text:007710AB push ecx
- .text:007710AC mov ecx, esi
- .text:007710AE call sub_551B90
- .text:007710B3 mov edx, [esp+120h+var_10C]
- .text:007710B7 push edx
- .text:007710B8 mov ecx, esi
- .text:007710BA call sub_76F290
- .text:007710BF test eax, eax
- .text:007710C1 jz short loc_7710CA
- .text:007710C3 movss xmm0, dword ptr [eax+10h]
- .text:007710C8 jmp short loc_7710D2
- .text:007710CA ; ---------------------------------------------------------------------------
- .text:007710CA
- .text:007710CA loc_7710CA: ; CODE XREF: sub_770F40+181j
- .text:007710CA movss xmm0, ds:dword_206AF48
- .text:007710D2
- .text:007710D2 loc_7710D2: ; CODE XREF: sub_770F40+188j
- .text:007710D2 movss [esp+120h+var_100], xmm0
- .text:007710D8 test eax, eax
- .text:007710DA jz short loc_7710E3
- .text:007710DC movss xmm0, dword ptr [eax+18h]
- .text:007710E1 jmp short loc_7710E6
- .text:007710E3 ; ---------------------------------------------------------------------------
- .text:007710E3
- .text:007710E3 loc_7710E3: ; CODE XREF: sub_770F40+19Aj
- .text:007710E3 xorps xmm0, xmm0
- .text:007710E6
- .text:007710E6 loc_7710E6: ; CODE XREF: sub_770F40+1A1j
- .text:007710E6 lea eax, [esp+120h+var_70]
- .text:007710ED push eax
- .text:007710EE movss [esp+124h+var_10C], xmm0
- .text:007710F4 xorps xmm0, xmm0
- .text:007710F7 push edi
- .text:007710F8 movaps [esp+128h+var_80], xmm0
- .text:00771100 movaps [esp+128h+var_70], xmm0
- .text:00771108 call sub_7690E0
- .text:0077110D add esp, 8
- .text:00771110 test al, al
- .text:00771112 jz short loc_77112F
- .text:00771114 mov ecx, [esp+120h+var_104]
- .text:00771118 movss xmm0, dword ptr [ecx+0F0h]
- .text:00771120 cvtss2sd xmm1, [esp+120h+var_100]
- .text:00771126 cvtps2pd xmm0, xmm0
- .text:00771129 mulsd xmm0, xmm1
- .text:0077112D jmp short loc_771132
- .text:0077112F ; ---------------------------------------------------------------------------
- .text:0077112F
- .text:0077112F loc_77112F: ; CODE XREF: sub_770F40+1D2j
- .text:0077112F xorps xmm0, xmm0
- .text:00771132
- .text:00771132 loc_771132: ; CODE XREF: sub_770F40+1EDj
- .text:00771132 mov edx, [esp+120h+var_F8]
- .text:00771136 cvtss2sd xmm1, [esp+120h+var_10C]
- .text:0077113C mov esi, [edx+0B8h]
- .text:00771142 cvtpd2ps xmm0, xmm0
- .text:00771146 movss [esp+120h+var_104], xmm0
- .text:0077114C cvtss2sd xmm0, xmm0
- .text:00771150 comisd xmm0, xmm1
- .text:00771154 jbe loc_771223
- .text:0077115A movaps xmm0, [esp+120h+var_80]
- .text:00771162 or [esp+120h+var_90], 1
- .text:0077116A xor eax, eax
- .text:0077116C movaps [esp+120h+var_C0], xmm0
- .text:00771171 xorps xmm0, xmm0
- .text:00771174 movss [esp+120h+var_A4], xmm0
- .text:0077117A movss [esp+120h+var_A0], xmm0
- .text:00771183 movaps xmm0, [esp+120h+var_F0]
- .text:00771188 mov [esp+120h+var_AC], eax
- .text:0077118C mov [esp+120h+var_A8], eax
- .text:00771190 mov [esp+120h+var_94], eax
- .text:00771197 mov eax, [esp+120h+var_FC]
- .text:0077119B movaps [esp+120h+var_D0], xmm0
- .text:007711A0 movq xmm0, qword ptr [eax+30h]
- .text:007711A5 or ecx, 0FFFFFFFFh
- .text:007711A8 movq [esp+120h+var_E0], xmm0
- .text:007711AE movq xmm0, qword ptr [eax+38h]
- .text:007711B3 lea eax, [esp+120h+var_F0]
- .text:007711B7 mov [esp+120h+var_9C], ecx
- .text:007711BE mov [esp+120h+var_98], ecx
- .text:007711C5 push eax
- .text:007711C6 mov ecx, ebx
- .text:007711C8 movq [esp+124h+var_D8], xmm0
- .text:007711CE call sub_11ED3A0
- .text:007711D3 push esi
- .text:007711D4 lea ecx, [esp+124h+var_E0]
- .text:007711D8 mov [esp+124h+var_98], eax
- .text:007711DF call sub_762E70
- .text:007711E4 mov ebx, [esp+120h+var_F4]
- .text:007711E8 movss xmm0, [esp+120h+var_104]
- .text:007711EE mov ecx, ebx
- .text:007711F0 movss [esp+120h+var_A4], xmm0
- .text:007711F6 mov [esp+120h+var_108], 0
- .text:007711FE mov [esp+120h+var_10C], esi
- .text:00771202 call sub_11EE830
- .text:00771207 mov edx, [edi]
- .text:00771209 mov edx, [edx+0F8h]
- .text:0077120F mov [esp+120h+var_108], eax
- .text:00771213 lea eax, [esp+120h+var_10C]
- .text:00771217 push eax
- .text:00771218 lea ecx, [esp+124h+var_E0]
- .text:0077121C push ecx
- .text:0077121D mov ecx, edi
- .text:0077121F call edx
- .text:00771221 jmp short loc_771227
- .text:00771223 ; ---------------------------------------------------------------------------
- .text:00771223
- .text:00771223 loc_771223: ; CODE XREF: sub_770F40+214j
- .text:00771223 mov ebx, [esp+120h+var_F4]
- .text:00771227
- .text:00771227 loc_771227: ; CODE XREF: sub_770F40+2E1j
- .text:00771227 lea ecx, [esp+120h+var_60]
- .text:0077122E call sub_1FD7220
- .text:00771233 movaps xmm0, [esp+120h+var_F0]
- .text:00771238 movaps [esp+120h+var_30], xmm0
- .text:00771240 movq xmm0, qword ptr [ebx+60h]
- .text:00771245 movq [esp+120h+var_20], xmm0
- .text:0077124E movq xmm0, qword ptr [ebx+68h]
- .text:00771253 xor ebx, ebx
- .text:00771255 movq [esp+120h+var_18], xmm0
- .text:0077125E mov [esp+120h+var_8], ebx
- .text:00771265 mov [esp+120h+var_C], 8
- .text:00771270 cmp esi, ebx
- .text:00771272 jz short loc_77127F
- .text:00771274 mov eax, [esi]
- .text:00771276 mov edx, [eax+10h]
- .text:00771279 mov ecx, esi
- .text:0077127B call edx
- .text:0077127D jmp short loc_771282
- .text:0077127F ; ---------------------------------------------------------------------------
- .text:0077127F
- .text:0077127F loc_77127F: ; CODE XREF: sub_770F40+332j
- .text:0077127F or eax, 0FFFFFFFFh
- .text:00771282
- .text:00771282 loc_771282: ; CODE XREF: sub_770F40+33Dj
- .text:00771282 mov [esp+120h+var_4], eax
- .text:00771289 lea eax, [esp+120h+var_60]
- .text:00771290 push eax
- .text:00771291 mov ecx, edi
- .text:00771293 call sub_118CD30
- .text:00771298 test byte ptr [esp+120h+var_10], 1
- .text:007712A0 jnz short loc_7712B9
- .text:007712A2 mov ecx, [esp+120h+var_10]
- .text:007712A9 cmp ecx, ebx
- .text:007712AB jz short loc_7712B9
- .text:007712AD call sub_448320
- .text:007712B2 mov [esp+120h+var_10], ebx
- .text:007712B9
- .text:007712B9 loc_7712B9: ; CODE XREF: sub_770F40+360j
- .text:007712B9 ; sub_770F40+36Bj
- .text:007712B9 lea ecx, [esp+120h+var_60]
- .text:007712C0 call sub_493A70
- .text:007712C5 pop edi
- .text:007712C6 pop esi
- .text:007712C7 mov al, 1
- .text:007712C9 pop ebx
- .text:007712CA mov esp, ebp
- .text:007712CC pop ebp
- .text:007712CD retn 4
- .text:007712CD sub_770F40 endp
- .text:007712CD
- .text:007712D0
- .text:007712D0 ; =============== S U B R O U T I N E =======================================
- .text:007712D0
- .text:007712D0 ; Attributes: bp-based frame
- .text:007712D0
- .text:007712D0 sub_7712D0 proc
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement