Function at 0x4086a0
Capabilities:
Read file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4824da
mov eax, dword fs:[0]
push eax
sub esp, 0x264
mov eax, dword [0x49b1b0]
xor eax, esp
mov dword [esp + 0x260], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x49b1b0]
xor eax, esp
push eax
lea eax, [esp + 0x278]
mov dword fs:[0], eax
mov edi, ecx
mov ecx, dword [edi + 0x1ec]
xor ebx, ebx
cmp ecx, ebx
je 0x4086f7
mov eax, dword [ecx]
mov edx, dword [eax]
push 1
call edx
mov dword [edi + 0x1ec], ebx
push 0x206
lea eax, [esp + 0x72]
push ebx
push eax
mov word [esp + 0x78], bx
call fcn.0046ce70
add esp, 0xc
push 0x104
lea ecx, [esp + 0x70]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
lea eax, [edi + 0x1c]
push 0x2723
mov dword [esp + 0x34], eax
call fcn.0043cca0
mov ebp, eax
cmp ebp, ebx
je 0x4087aa
lea eax, [esp + 0x6c]
mov dword [esp + 0x4c], 7
mov dword [esp + 0x48], ebx
mov word [esp + 0x38], bx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x408756
sub eax, edx
sar eax, 1
push eax
lea edx, [esp + 0x70]
push edx
lea esi, [esp + 0x3c]
call fcn.00401df0
mov dword [esp + 0x280], ebx
mov eax, dword [ebp]
mov edx, dword [eax + 0x144]
mov ecx, esi
push ecx
mov ecx, ebp
call edx
mov dword [esp + 0x280], 0xffffffff
cmp dword [esp + 0x4c], 8
jb 0x4087aa
mov eax, dword [esp + 0x38]
push eax
call fcn.00469d48
add esp, 4
mov al, byte [edi + 0x1d4]
cmp al, bl
je 0x40891c
lea eax, [esp + 0x6c]
mov dword [esp + 0x4c], 7
mov dword [esp + 0x48], ebx
mov word [esp + 0x38], bx
lea edx, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x4087d0
sub eax, edx
sar eax, 1
push eax
lea ecx, [esp + 0x70]
push ecx
lea esi, [esp + 0x3c]
call fcn.00401df0
mov eax, dword [esp + 0x38]
mov esi, 8
cmp dword [esp + 0x4c], esi
lea ebp, [edi + 0x240]
jae 0x408807
lea eax, [esp + 0x38]
push ebx
push 0x80
push 3
push ebx
push 1
push SysReAllocString
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
cmp dword [esp + 0x4c], esi
mov dword [ebp], eax
jb 0x408834
mov edx, dword [esp + 0x38]
push edx
call fcn.00469d48
add esp, 4
cmp dword [ebp], 0xffffffff
je 0x40891c
mov eax, dword [edi + 0x1dc]
cmp eax, ebx
mov ecx, dword [edi + 0x1d8]
ja 0x408856
cmp ecx, ebx
jbe 0x40891c
mov edx, 0xfffffff8
sub edx, ecx
push 2
mov ecx, 0xffffffff
sbb ecx, eax
push ecx
push edx
lea esi, [esp + 0x28]
mov eax, ebp
call fcn.004155a0
mov eax, dword [ebp]
cmp eax, 0xffffffff
je 0x408893
push ebx
lea edx, [esp + 0x18]
push edx
push 8
lea ecx, [esp + 0x30]
push ecx
push eax
mov dword [esp + 0x28], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, 0xfffffff8
sub edx, dword [esp + 0x24]
mov eax, 0xffffffff
sbb eax, dword [esp + 0x28]
push 1
push eax
push edx
lea esi, [esp + 0x28]
mov eax, ebp
call fcn.004155a0
mov ecx, dword [edi + 0x1ec]
cmp ecx, ebx
je 0x4088c6
mov edx, dword [ecx]
mov eax, dword [edx]
push 1
call eax
push 0x118
call fcn.00469d66
add esp, 4
mov dword [esp + 0x1c], eax
cmp eax, ebx
mov dword [esp + 0x280], 1
je 0x4088ef
push ebp
push eax
call fcn.00419390
jmp 0x4088f1
xor eax, eax
mov dword [esp + 0x280], 0xffffffff
mov dword [edi + 0x1ec], eax
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [edi + 0x1ec]
add ecx, 8
push ecx
mov ecx, edi
call fcn.00407de0
push 1
push 0x2712
mov ecx, edi
call fcn.00408c30
push 5
push 0x2714
mov ecx, edi
call fcn.00408c30
push 4
push 0x2717
mov ecx, edi
call fcn.00408c30
mov edx, dword [edi + 0x1cc]
lea ebp, [edi + 0x1c8]
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x28]
mov esi, ebp
mov dword [esp + 0x18], 8
mov dword [esp + 0x24], edx
call fcn.0040b1e0
mov esi, eax
mov eax, dword [esi]
cmp eax, ebx
je 0x40897a
cmp eax, ebp
je 0x40897f
call fcn.00469efa
mov ecx, dword [esp + 0x20]
cmp dword [esi + 4], ecx
je 0x408bf9
mov eax, dword [esp + 0x30]
push 0x271c
call fcn.0043cca0
mov edi, eax
cmp edi, ebx
mov dword [esp + 0x24], edi
je 0x408ac6
mov edx, dword [edi]
mov eax, dword [edx + 0xc4]
push 1
mov ecx, edi
call eax
mov dword [esp + 0x34], vtable.GameMgr::GMBuffer_unsigned_char_.0
mov dword [esp + 0x38], ebx
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x280], 2
lea edx, [esp + 0x14]
mov eax, ebp
mov dword [esp + 0x14], 8
call fcn.0040b160
mov edi, dword [eax]
lea esi, [esp + 0x34]
call fcn.0040cb00
mov edi, 8
lea edx, [esp + 0x14]
mov eax, ebp
mov dword [esp + 0x14], edi
mov dword [esp + 0x1c], edi
call fcn.0040b160
mov ecx, dword [eax]
push ecx
lea edx, [esp + 0x20]
mov eax, ebp
call fcn.0040b160
mov edx, dword [eax + 4]
mov esi, dword [esp + 0x40]
push edx
push esi
call fcn.0046cef0
add esp, 0xc
mov dword [esp + 0x14], ebx
call fcn.004051f0
lea eax, [esp + 0x14]
push eax
lea eax, [esp + 0x38]
call fcn.0043f390
mov eax, dword [esp + 0x14]
cmp eax, ebx
je 0x408aaa
push eax
push ebx
call fcn.004051f0
call fcn.004401e0
mov dword [esp + 0x68], 7
mov dword [esp + 0x64], ebx
mov word [esp + 0x54], bx
push eax
lea ecx, [esp + 0x54]
push str.res_d_restypePNG
push ecx
mov byte [esp + 0x28c], 3
call fcn.00417f20
mov eax, dword [esp + 0x30]
add esp, 0xc
push 0xffffffffffffffff
push ebx
lea edx, [esp + 0x58]
push edx
add eax, 0x1c4
call fcn.00401c40
cmp dword [esp + 0x68], edi
jb 0x408aaa
mov eax, dword [esp + 0x54]
push eax
call fcn.00469d48
add esp, 4
cmp esi, ebx
mov dword [esp + 0x280], 0xffffffff
je 0x408ac2
push esi
call fcn.00469cbe
add esp, 4
mov edi, dword [esp + 0x24]
mov ecx, dword [ebp + 4]
lea edx, [esp + 0x1c]
push edx
lea eax, [esp + 0x28]
mov esi, ebp
mov dword [esp + 0x20], 9
mov dword [esp + 0x1c], ecx
call fcn.0040b1e0
mov esi, eax
mov eax, dword [esi]
cmp eax, ebx
je 0x408af1
cmp eax, ebp
je 0x408af6
call fcn.00469efa
mov eax, dword [esp + 0x18]
cmp dword [esi + 4], eax
je 0x408b9d
lea edx, [esp + 0x1c]
mov eax, ebp
mov dword [esp + 0x1c], 9
call fcn.0040b160
mov eax, dword [eax + 4]
mov ebp, 7
mov ecx, eax
mov dword [esp + 0x68], ebp
mov dword [esp + 0x64], ebx
mov word [esp + 0x54], bx
lea esi, [ecx + 2]
mov dx, word [ecx]
add ecx, 2
cmp dx, bx
jne 0x408b30
sub ecx, esi
sar ecx, 1
push ecx
push eax
lea esi, [esp + 0x58]
call fcn.00401df0
mov dword [esp + 0x280], 4
cmp dword [esp + 0x64], ebx
je 0x408b71
mov edx, dword [edi]
mov eax, dword [edx + 0x158]
push str.setcursor
push str.flags
mov ecx, edi
call eax
mov dword [esp + 0x280], 0xffffffff
cmp dword [esp + 0x68], 8
jb 0x408b90
mov ecx, dword [esp + 0x54]
push ecx
call fcn.00469d48
add esp, 4
mov dword [esp + 0x68], ebp
mov dword [esp + 0x64], ebx
mov word [esp + 0x54], bx
mov eax, dword [esp + 0x30]
push 0x271b
call fcn.0043cca0
cmp eax, ebx
je 0x408bd8
mov ebp, dword [eax]
mov edi, 1
sub esp, 0x10
mov edx, esp
mov ecx, edi
mov dword [edx], ecx
mov esi, edi
mov dword [edx + 4], esi
mov dword [edx + 8], edi
mov dword [edx + 0xc], ecx
mov edx, dword [ebp + 0x1f0]
mov ecx, eax
mov dword [esp + 0x50], edi
call edx
mov eax, dword [esp + 0x30]
push 0x2713
call fcn.0043cca0
cmp eax, ebx
je 0x408c07
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc4]
push ebx
call eax
jmp 0x408c07
push 2
push 0x2713
mov ecx, edi
call fcn.00408c30
mov ecx, dword [esp + 0x278]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x260]
xor ecx, esp
call fcn.00469ab5
add esp, 0x270
ret