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

Disassembly:
sub esp, 0xf8
mov eax, dword [0x5b7b5c]
xor eax, esp
mov dword [esp + 0xf4], eax
push ebx
push ebp
push esi
mov esi, ecx
mov eax, dword [esi + 0x70]
mov ecx, dword [esi + 0x74]
push edi
push eax
push ecx
mov ecx, dword [esi + 0xa0]
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x1c]
push eax
call fcn.00472d20
mov ecx, dword [esp + 0x10]
test ecx, ecx
jle 0x491e88
mov eax, dword [esi + 0x160]
cdq
idiv dword [0x5c3e74]
add eax, dword [esi + 0x7c]
cmp ecx, eax
jle 0x491e88
dec ecx
mov dword [esp + 0x10], ecx
push ecx
mov ecx, dword [esi + 0xa0]
call fcn.0048c200
mov dword [esp + 0x20], eax
mov eax, dword [esi + 0x74]
mov edi, dword [esi + 0x78]
lea ecx, [eax + 1]
mov dword [esp + 0x18], ecx
mov ecx, dword [esi + 0xa0]
lea edx, [eax + eax*8]
mov eax, dword [ecx + 0x334]
mov eax, dword [eax + edx*4 + 8]
mov ecx, dword [ecx + 0x10c]
mov edx, dword [esi + 0x70]
push ecx
push edx
push eax
call fcn.00485ed0
lea ebp, [eax + edi + 1]
mov eax, dword [esi + 0x194]
add esp, 0xc
or ebx, 0xffffffff
mov dword [esp + 0x14], ebp
cmp eax, dword [esp + 0x10]
jne 0x491ed7
mov dword [esp + 0x18], ebx
cmp dword [esi + 0x190], ebp
jne 0x491eed
cmp dword [esi + 0x198], edi
jne 0x491eed
mov dword [esp + 0x14], ebx
mov ebp, ebx
mov ecx, dword [esp + 0x18]
cmp ecx, ebx
jne 0x491ef9
cmp ebp, ebx
je 0x491f16
mov eax, dword [esi + 0x74]
mov edi, dword [esi + 0x70]
lea edx, [eax + eax*8]
mov eax, dword [esi + 0xa0]
mov eax, dword [eax + 0x334]
mov edx, dword [eax + edx*4 + 8]
movzx ebx, word [edx + edi*2]
cmp dword [esi + 0x128], 0
je 0x492094
mov edi, dword [sym.imp.USER32.dll_LoadStringW]
test ecx, ecx
jl 0x491f7b
call fcn.0050b420
mov eax, dword [eax + 0xc]
push 0x64
lea ecx, [esp + 0xa4]
push ecx
push 0x53c8
push eax
call edi
mov edx, dword [esp + 0x18]
push edx
lea eax, [esp + 0xa4]
push eax
lea ecx, [esp + 0x44]
push ecx
call fcn.00401320
mov ecx, dword [0x5ed0c0]
add esp, 0xc
push 1
lea edx, [esp + 0x40]
push edx
push 1
add ecx, 0xec
call fcn.0051afed
test ebp, ebp
jl 0x491fc9
call fcn.0050b420
mov eax, dword [eax + 0xc]
push 0x64
lea ecx, [esp + 0xa4]
push ecx
push 0x5ba1
push eax
call edi
push ebp
lea edx, [esp + 0xa4]
push edx
lea eax, [esp + 0x44]
push eax
call fcn.00401320
add esp, 0xc
push 1
lea ecx, [esp + 0x40]
push ecx
mov ecx, dword [0x5ed0c0]
push 2
add ecx, 0xec
call fcn.0051afed
test ebx, ebx
jl 0x49200e
mov dword [0x5ed114], ebx
mov eax, str._04X
test ebx, 0xff00
jne 0x491fe5
mov eax, 0x579c80
push ebx
push eax
lea edx, [esp + 0x44]
push edx
call fcn.00401320
mov ecx, dword [0x5ed0c0]
add esp, 0xc
push 1
lea eax, [esp + 0x40]
push eax
push 4
add ecx, 0xec
call fcn.0051afed
cmp dword [0x5ed730], 0
je 0x492094
mov eax, dword [esi + 0xa0]
mov ecx, dword [eax + 0x154]
cmp ecx, dword [0x5ed110]
je 0x492094
mov edx, 9
mov word [esp + 0x3e], dx
mov ecx, edx
push 0x30
lea edx, [esp + 0x44]
mov word [esp + 0x40], cx
mov eax, dword [eax + 0x154]
push edx
push eax
call fcn.0044d1d0
mov eax, dword [0x5ba378]
add esp, 0xc
xor edx, edx
cmp dword [eax + 0xc4], 0x3b5
push 1
sete dl
lea ecx, [esp + 0x40]
push ecx
mov ecx, dword [0x5ed0c0]
add ecx, 0xec
add edx, 0xa
push edx
call fcn.0051afed
mov ecx, dword [esi + 0xa0]
mov edx, dword [ecx + 0x154]
mov dword [0x5ed110], edx
mov eax, dword [esi + 0x194]
xor edi, edi
cmp eax, dword [esp + 0x10]
je 0x4920a7
mov edi, 1
mov ecx, dword [esi + 0xa0]
cmp dword [ecx + 0x9c], 0
je 0x4920be
mov edx, dword [ecx + 0x300]
jmp 0x4920db
cmp dword [ecx + 0x78], 0
jne 0x4920d5
cmp dword [ecx + 0x84], 0
jne 0x4920d5
mov edx, dword [ecx + 0x2e8]
jmp 0x4920db
mov edx, dword [ecx + 0x184]
dec edx
cmp eax, edx
jl 0x492111
cmp dword [ecx + 0x9c], 0
je 0x4920f1
mov ecx, dword [ecx + 0x300]
jmp 0x49210e
cmp dword [ecx + 0x78], 0
jne 0x492108
cmp dword [ecx + 0x84], 0
jne 0x492108
mov ecx, dword [ecx + 0x2e8]
jmp 0x49210e
mov ecx, dword [ecx + 0x184]
lea eax, [ecx - 1]
mov dword [esi + 0x194], eax
test edi, edi
je 0x4922dc
mov ecx, dword [esi + 0x7c]
mov edx, dword [0x5c3e74]
mov edi, dword [esp + 0x10]
mov ebp, dword [esi + 0x164]
sub eax, ecx
imul eax, edx
sub edi, ecx
imul edi, edx
cmp dword [0x5ed824], 0
mov ebx, eax
je 0x492190
cmp dword [esi + 0x1f4], 0
jne 0x492159
cmp dword [esi + 0x1f8], 0
je 0x49216a
push 0
push 1
mov ecx, esi
call fcn.0048e970
mov edx, dword [0x5c3e74]
add edx, ebx
push edx
push ebp
push ebx
push 0
mov ecx, esi
call fcn.00490750
mov eax, dword [0x5c3e74]
add eax, edi
push eax
push ebp
push edi
push 0
mov ecx, esi
call fcn.00490750
jmp 0x4922d8
cmp dword [esi + 0x128], 0
je 0x4922d8
mov ecx, dword [esi + 0x20]
push ecx
call dword [sym.imp.USER32.dll_GetDC]
mov ecx, dword [esi + 0x68]
mov ebp, eax
mov eax, dword [0x5ed84c]
cdq
sub eax, edx
add ebx, ecx
add edi, ecx
sar eax, 1
mov edx, 0
sets dl
dec edx
and edx, eax
cmp ebx, ecx
mov dword [esp + 0x1c], edx
jl 0x492283
mov edx, dword [0x5ba1f0]
mov eax, dword [0x5c3e74]
mov ecx, dword [0x5ed13c]
push edx
add eax, ebx
push ebp
mov dword [esp + 0x30], 0
mov dword [esp + 0x34], ebx
mov dword [esp + 0x3c], eax
mov dword [esp + 0x38], ecx
call dword [sym.imp.GDI32.dll_SetBkColor]
push 0
push 0
push 0
lea eax, [esp + 0x34]
push eax
push 2
push 0
push 0
push ebp
call dword [sym.imp.GDI32.dll_ExtTextOutW]
mov ecx, dword [0x5ba1e0]
push ecx
push ebp
call dword [sym.imp.GDI32.dll_SetBkColor]
mov edx, dword [esi + 0x194]
mov ecx, dword [esi + 0xa0]
push edx
call fcn.00470e50
test eax, eax
jne 0x492283
push eax
mov eax, dword [esi + 0x194]
push eax
lea ecx, [esp + 0x40]
push ecx
mov ecx, dword [esi + 0xa0]
lea edx, [esp + 0x30]
push edx
call fcn.00473590
mov eax, dword [esp + 0x24]
mov ecx, dword [esi + 0xa0]
lea edx, [eax + eax*8]
mov eax, dword [ecx + 0x334]
cmp dword [eax + edx*4 + 0x14], 0
je 0x492283
mov ecx, dword [esp + 0x1c]
add ecx, ebx
push ecx
push ebp
call fcn.0040d1d0
add esp, 8
cmp edi, dword [esi + 0x68]
jl 0x4922cd
mov eax, dword [esi + 0x74]
mov ecx, dword [esi + 0xa0]
lea edx, [eax + eax*8]
mov eax, dword [ecx + 0x334]
cmp dword [eax + edx*4 + 0x14], 0
je 0x4922b6
mov edx, dword [esp + 0x10]
push edx
call fcn.00470e50
test eax, eax
jne 0x4922b6
mov eax, 1
jmp 0x4922b8
xor eax, eax
push eax
mov eax, dword [esp + 0x20]
add eax, edi
push eax
push 0
push ebp
mov ecx, 0x5ba30c
call fcn.0040d500
mov ecx, dword [esi + 0x20]
push ebp
push ecx
call dword [sym.imp.USER32.dll_ReleaseDC]
mov ebp, dword [esp + 0x14]
mov edx, dword [esp + 0x10]
mov eax, dword [esi + 0x78]
mov dword [esi + 0x194], edx
mov dword [esi + 0x190], ebp
mov dword [esi + 0x198], eax
cmp dword [0x5ed82c], 0
je 0x49233f
mov ecx, dword [esi + 0x70]
mov edx, dword [esi + 0x74]
push 1
push 1
push ecx
push edx
mov ecx, esi
call fcn.0048c4b0
mov edi, eax
add edi, dword [esi + 0x78]
mov eax, dword [esi + 0x90]
cmp edi, eax
je 0x49233f
cmp dword [esi + 0x128], 0
mov dword [esi + 0x90], edi
je 0x49233f
push eax
mov ecx, esi
call fcn.00487e10
push edi
mov ecx, esi
call fcn.00487e10
cmp dword [esp + 0x18], 0
jge 0x49234a
test ebp, ebp
jl 0x492355
push 0
push 0
mov ecx, esi
call fcn.0048e970
mov ecx, dword [esp + 0x104]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.0053f73f
add esp, 0xf8
ret