Function at 0x1005b490
Capabilities:
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x88
push ebx
push ebp
mov ebx, ecx
xor ebp, ebp
mov dword [esp + 0x18], ebp
push esi
push edi
test ebx, ebx
je 0x1005b854
mov edi, dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push ebp
call edi
mov esi, eax
mov dword [esp + 0x10], esi
test esi, esi
je 0x1005b854
mov ebp, dword [sym.imp.GDI32.dll_GetObjectW]
lea eax, [esp + 0x3c]
push eax
push 0x18
push ebx
call ebp
mov eax, dword [esp + 0x40]
push 0
mov dword [esp + 0x5c], eax
mov eax, dword [esp + 0x48]
push 0
mov dword [esp + 0x64], eax
lea eax, [esp + 0x9c]
push eax
push 0
lea eax, [esp + 0x64]
mov dword [esp + 0x64], 0x28
push eax
push esi
mov dword [esp + 0x78], 0x200001
mov dword [esp + 0x7c], 0
mov dword [esp + 0x80], 0
mov dword [esp + 0x84], 0
mov dword [esp + 0x88], 0
mov dword [esp + 0x8c], 0
mov dword [esp + 0x90], 0
call dword [sym.imp.GDI32.dll_CreateDIBSection]
mov esi, eax
test esi, esi
je 0x1005b83b
push esi
push dword [esp + 0x14]
call dword [sym.imp.GDI32.dll_SelectObject]
push dword [esp + 0x10]
mov dword [esp + 0x3c], eax
call edi
mov edi, eax
mov dword [esp + 0x34], edi
test edi, edi
je 0x1005b80d
lea eax, [esp + 0x7c]
push eax
push 0x18
push esi
call ebp
mov ecx, dword [esp + 0x88]
mov eax, ecx
and eax, reloc.WS2_32.dll_closesocket
jns 0x1005b596
dec eax
or eax, 0xfffffffc
inc eax
je 0x1005b5b0
inc ecx
mov eax, ecx
and eax, reloc.WS2_32.dll_closesocket
jns 0x1005b5a7
dec eax
or eax, 0xfffffffc
inc eax
jne 0x1005b598
mov dword [esp + 0x88], ecx
push ebx
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
push 0xcc0020
push 0
push 0
push edi
push dword [esp + 0x54]
mov dword [esp + 0x44], eax
push dword [esp + 0x54]
push 0
push 0
push dword [esp + 0x30]
call dword [sym.imp.GDI32.dll_BitBlt]
push 0x660
mov ebp, 0x64
push 2
mov dword [esp + 0x20], ebp
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
mov dword [esp + 0x2c], eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov edi, eax
push 0
push 0
push closesocket
push closesocket
lea eax, [edi + 0x10]
mov dword [edi], 0x20
push eax
mov dword [edi + 4], 1
mov dword [edi + 0xc], 0
mov dword [edi + 8], 0
call dword [sym.imp.USER32.dll_SetRect]
mov ecx, dword [esp + 0x84]
xor ebx, ebx
mov eax, dword [esp + 0x88]
dec ecx
imul ecx, eax
mov dword [esp + 0x1c], ebx
add ecx, dword [esp + 0x90]
mov dword [esp + 0x24], ecx
mov ecx, dword [esp + 0x44]
test ecx, ecx
jle 0x1005b7c7
mov edx, dword [esp + 0x40]
xor esi, esi
test edx, edx
jle 0x1005b7b6
lea ebx, [ebp + 2]
shl ebx, 4
mov dword [esp + 0x14], ebx
nop dword [eax]
mov eax, dword [esp + 0x24]
mov ebp, esi
mov dword [esp + 0x2c], ebp
lea eax, [eax + esi*4]
cmp esi, edx
jge 0x1005b79a
mov cl, byte [eax]
test cl, cl
jne 0x1005b6a9
mov cl, byte [eax + 1]
test cl, cl
jne 0x1005b6a9
mov cl, byte [eax + 2]
test cl, cl
je 0x1005b6b1
inc esi
add eax, 4
cmp esi, edx
jl 0x1005b695
cmp esi, ebp
jle 0x1005b79a
mov eax, dword [esp + 0x18]
cmp dword [edi + 8], eax
jb 0x1005b6f3
mov edi, dword [esp + 0x28]
push edi
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
add dword [esp + 0x18], 0x64
add ebx, 0x640
push 2
push ebx
push edi
mov dword [esp + 0x20], ebx
call dword [sym.imp.KERNEL32.dll_GlobalReAlloc]
push eax
mov dword [esp + 0x2c], eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov edi, eax
mov eax, dword [esp + 0x1c]
lea ebx, [eax + 1]
push ebx
push esi
push eax
mov eax, dword [edi + 8]
add eax, 2
shl eax, 4
push ebp
add eax, edi
push eax
call dword [sym.imp.USER32.dll_SetRect]
mov eax, dword [esp + 0x2c]
lea ebp, [edi + 0x10]
cmp eax, dword [ebp]
jge 0x1005b71f
mov dword [ebp], eax
mov eax, dword [esp + 0x1c]
cmp eax, dword [edi + 0x14]
jge 0x1005b72b
mov dword [edi + 0x14], eax
cmp esi, dword [edi + 0x18]
jle 0x1005b733
mov dword [edi + 0x18], esi
cmp ebx, dword [edi + 0x1c]
jle 0x1005b73b
mov dword [edi + 0x1c], ebx
inc dword [edi + 8]
cmp dword [edi + 8], 0x7d0
jne 0x1005b792
push edi
push dword [esp + 0x18]
push 0
call dword [sym.imp.GDI32.dll_ExtCreateRegion]
mov ebx, eax
mov eax, dword [esp + 0x20]
test eax, eax
je 0x1005b772
push 2
push ebx
push eax
push eax
call dword [sym.imp.GDI32.dll_CombineRgn]
push ebx
call dword [sym.imp.GDI32.dll_DeleteObject]
jmp 0x1005b776
mov dword [esp + 0x20], ebx
push 0
push 0
push closesocket
push closesocket
push ebp
mov dword [edi + 8], 0
call dword [sym.imp.USER32.dll_SetRect]
mov ebx, dword [esp + 0x14]
mov edx, dword [esp + 0x40]
inc esi
cmp esi, edx
jl 0x1005b680
mov ecx, dword [esp + 0x44]
mov eax, dword [esp + 0x88]
mov ebx, dword [esp + 0x1c]
mov ebp, dword [esp + 0x18]
sub dword [esp + 0x24], eax
inc ebx
mov dword [esp + 0x1c], ebx
cmp ebx, ecx
jl 0x1005b665
push edi
lea eax, [ebp + 2]
shl eax, 4
push eax
push 0
call dword [sym.imp.GDI32.dll_ExtCreateRegion]
mov ebx, dword [esp + 0x20]
mov esi, eax
test ebx, ebx
je 0x1005b7f5
push 2
push esi
push ebx
push ebx
call dword [sym.imp.GDI32.dll_CombineRgn]
push esi
call dword [sym.imp.GDI32.dll_DeleteObject]
mov esi, ebx
push dword [esp + 0x30]
mov edi, dword [esp + 0x38]
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
push edi
call dword [sym.imp.GDI32.dll_DeleteDC]
jmp 0x1005b80f
xor esi, esi
push dword [esp + 0x38]
push dword [esp + 0x14]
call dword [sym.imp.GDI32.dll_SelectObject]
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
push dword [esp + 0x10]
call dword [sym.imp.GDI32.dll_DeleteDC]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret
push dword [esp + 0x10]
xor esi, esi
call dword [sym.imp.GDI32.dll_DeleteDC]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x88
ret
pop edi
pop esi
mov eax, ebp
pop ebp
pop ebx
add esp, 0x88
ret