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

Disassembly:
sub esp, 0x5c
push ebx
mov ebx, dword [esp + 0x64]
push ebp
xor ebp, ebp
push esi
mov esi, dword [esp + 0x74]
push edi
mov edi, dword [esp + 0x74]
mov dword [esp + 0x28], ebp
mov dword [esp + 0x24], ebp
mov dword [esp + 0x2c], ebp
mov dword [esp + 0x3c], ebp
mov dword [esp + 0x38], ebp
mov dword [esp + 0x34], ebp
mov dword [esp + 0x30], ebp
cmp esi, ebp
je 0x502134
mov eax, dword [ebx + 0x14]
push eax
call fcn.00503520
add esp, 4
mov dword [ebx + 0x14], ebp
mov ecx, dword [ebx + 8]
push ecx
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esp + 0x44], eax
cmp esi, ebp
je 0x502151
mov edx, dword [ebx]
push edx
push edi
call dword [sym.imp.GDI32.dll_SetTextColor]
push 0x18
push edi
call dword [sym.imp.GDI32.dll_SetTextAlign]
mov eax, dword [ebx + 0x10]
push eax
call dword [sym.imp.USER32.dll_GetWindowTextLengthA]
lea esi, [eax + 1]
push esi
call fcn.00494940
mov ecx, dword [ebx + 0x10]
add esp, 4
push esi
push eax
push ecx
mov dword [esp + 0x4c], eax
call dword [sym.imp.USER32.dll_GetWindowTextA]
mov eax, dword [ebx + 0x10]
lea edx, [esp + 0x5c]
push edx
push eax
call dword [sym.imp.USER32.dll_GetClientRect]
push 0x2c
mov dword [esp + 0x54], ebp
call fcn.00494940
push 0x2c
mov esi, eax
push ebp
push esi
call fcn.004948b0
mov dword [esi], 0x190
mov dword [esi + 4], ebp
mov dword [esi + 8], ebp
mov ecx, dword [ebx + 0xc]
mov dword [esi + 0x10], ecx
mov dword [esi + 0x14], ebp
mov edx, dword [ebx]
mov dword [esi + 0x18], edx
mov dword [esi + 0x20], ebp
mov dword [esi + 0x24], ebp
mov dword [esi + 0x1c], ebp
mov dword [esi + 0x28], ebp
push ebx
mov ecx, esi
mov dword [esp + 0x2c], esi
lea esi, [esp + 0x3c]
mov ebx, edi
call fcn.005015b0
mov dword [esp + 0x60], eax
mov eax, dword [esp + 0x78]
add esp, 0x14
mov dword [esp + 0x58], eax
xor eax, eax
mov dword [esp + 0x54], ebp
mov ebp, dword [esp + 0x40]
mov dword [esp + 0x1c], eax
mov dword [esp + 0x14], eax
mov dword [esp + 0x20], eax
mov ebx, eax
mov esi, eax
mov al, byte [ebp]
mov byte [esp + 0x13], al
cmp esi, 9
ja case.default.0x502216
jmp dword [esi*4 + 0x502bf0]
movsx eax, al
cmp eax, 0x3c
ja case.0x502230.1
movzx ecx, byte [eax + 0x502c2c]
jmp dword [ecx*4 + 0x502c18]
lea edx, [ebp + 1]
mov esi, 2
mov dword [esp + 0x24], edx
mov dword [esp + 0x2c], 0
jmp 0x502af5
mov esi, 9
jmp 0x5022b7
test ebx, ebx
je case.0x502230.0
cmp dword [ebx + 0x20], 0
jne case.0x502230.0
mov edx, dword [esp + 0x18]
push edx
lea eax, [esp + 0x24]
push eax
push ebp
mov eax, ebx
call fcn.00500a90
mov ecx, dword [esp + 0x84]
push ecx
lea edx, [esp + 0x38]
push edx
lea ecx, [esp + 0x64]
push ecx
lea edx, [esp + 0x38]
push edx
push eax
mov eax, dword [esp + 0x90]
push 1
push ebp
mov ecx, edi
call fcn.00501b10
mov ebx, eax
add esp, 0x28
mov dword [esp + 0x14], ebx
jmp case.0x502230.0
mov esi, 1
mov eax, dword [esp + 0x18]
push eax
lea ecx, [esp + 0x24]
push ecx
push ebp
mov eax, ebx
mov dword [esp + 0x28], esi
call fcn.00500a90
mov ebx, eax
add esp, 0xc
mov dword [esp + 0x14], ebx
jmp case.0x502230.0
movsx eax, al
cmp eax, 0x3c
ja case.0x502230.0
movzx edx, byte [eax + 0x502c7c]
jmp dword [edx*4 + 0x502c6c]
mov ecx, dword [esp + 0x78]
push ecx
lea eax, [ebp + 1]
lea edx, [esp + 0x2c]
mov dword [esp + 0x28], eax
push edx
lea eax, [esp + 0x58]
push eax
lea ecx, [esp + 0x2c]
push ecx
jmp 0x502962
mov edx, dword [esp + 0x78]
push edx
lea eax, [esp + 0x2c]
push eax
mov eax, dword [esp + 0x78]
lea ecx, [esp + 0x58]
push ecx
lea edx, [esp + 0x2c]
push edx
push ebx
push 0
push ebp
mov ecx, edi
call fcn.00501b10
mov ecx, dword [esp + 0x34]
push ecx
lea edx, [esp + 0x40]
push edx
push ebp
call fcn.00500a90
add esp, 0x28
mov esi, 9
jmp 0x502aef
mov eax, dword [esp + 0x78]
push eax
lea ecx, [esp + 0x2c]
push ecx
lea edx, [esp + 0x58]
push edx
lea eax, [esp + 0x2c]
push eax
jmp 0x502ad8
movsx eax, al
add eax, 0xfffffff6
cmp eax, 0x34
ja case.0x502230.0
movzx ecx, byte [eax + 0x502ccc]
jmp dword [ecx*4 + 0x502cbc]
cmp dword [esp + 0x24], 0
je 0x5023db
cmp dword [esp + 0x2c], 0
jne 0x5023db
mov eax, dword [esp + 0x78]
mov ebx, dword [esp + 0x70]
lea edx, [esp + 0x30]
push edx
push eax
lea ecx, [esp + 0x30]
push ecx
push edi
lea edx, [esp + 0x60]
push edx
mov edx, dword [esp + 0x38]
lea eax, [esp + 0x28]
push eax
mov eax, dword [esp + 0x30]
lea ecx, [esp + 0x38]
push ecx
push edx
mov ecx, ebp
mov dword [esp + 0x4c], ebp
call fcn.00501c00
mov ebx, dword [esp + 0x34]
add esp, 0x20
mov dword [esp + 0x18], eax
xor esi, esi
jmp 0x502af5
mov eax, dword [esp + 0x24]
test eax, eax
je 0x5023ff
cmp ebp, eax
jne 0x5023ff
lea eax, [ebp + 1]
mov dword [esp + 0x24], eax
mov esi, 8
jmp 0x502af5
cmp dword [esp + 0x2c], 0
jne 0x502448
mov edx, dword [esp + 0x78]
mov ebx, dword [esp + 0x70]
lea ecx, [esp + 0x30]
push ecx
push edx
lea eax, [esp + 0x30]
push eax
push edi
lea ecx, [esp + 0x60]
push ecx
mov ecx, dword [esp + 0x38]
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x38]
push eax
mov eax, dword [esp + 0x34]
push ecx
mov ecx, ebp
mov dword [esp + 0x4c], ebp
call fcn.00501c00
mov ebx, dword [esp + 0x34]
add esp, 0x20
mov dword [esp + 0x18], eax
mov ecx, dword [esp + 0x30]
mov eax, ecx
sub eax, 1
je 0x50256d
sub eax, 5
je 0x5024f6
sub eax, 1
jne 0x5025b9
mov esi, dword [esp + 0x78]
mov edx, dword [esp + 0x70]
push esi
push edx
push edi
lea eax, [esp + 0x5c]
push eax
xor ebx, ebx
push ebx
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x34]
call fcn.005016f0
add esp, 0x14
mov dword [esp + 0x14], ebx
mov dword [esp + 0x20], ebx
cmp esi, ebx
je 0x5024ec
mov ecx, dword [esp + 0x18]
mov edx, dword [ecx + 0x18]
push edx
push ebx
push ebx
call dword [sym.imp.GDI32.dll_CreatePen]
mov esi, eax
push esi
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
mov ebx, dword [esp + 0x50]
push 0
mov dword [esp + 0x4c], eax
mov eax, dword [esp + 0x58]
add ebx, 2
push ebx
push eax
push edi
call dword [sym.imp.GDI32.dll_MoveToEx]
mov ecx, dword [esp + 0x58]
push ebx
push ecx
push edi
call dword [sym.imp.GDI32.dll_LineTo]
mov edx, dword [esp + 0x48]
push edx
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
push esi
call dword [sym.imp.GDI32.dll_DeleteObject]
add dword [esp + 0x50], 5
jmp 0x5025c1
cmp dword [esp + 0x20], 0
jne 0x50251c
mov eax, dword [esp + 0x50]
add eax, dword [esp + 0x4c]
mov edi, dword [esp + 0x70]
push eax
lea ebx, [esp + 0x54]
mov dword [esp + 0x54], eax
call fcn.00500bd0
add esp, 4
jmp 0x502546
mov eax, dword [esp + 0x78]
mov ecx, dword [esp + 0x70]
push eax
push ecx
push edi
lea edx, [esp + 0x5c]
push edx
push 0
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x34]
call fcn.005016f0
add esp, 0x14
mov dword [esp + 0x20], 0
mov eax, dword [esp + 0x18]
mov ecx, dword [eax + 0x1c]
mov edx, dword [esp + 0x70]
push ecx
push edx
lea ebx, [esp + 0x58]
mov dword [esp + 0x1c], 0
call fcn.00500c40
mov edi, dword [esp + 0x7c]
add esp, 8
jmp 0x5025c1
mov eax, dword [esp + 0x18]
cmp dword [eax + 0x24], 0
je 0x5025c1
mov ecx, eax
push ecx
lea edx, [esp + 0x24]
push edx
push ebp
mov eax, ebx
call fcn.00500a90
mov ecx, dword [esp + 0x84]
push ecx
lea edx, [esp + 0x38]
push edx
lea ecx, [esp + 0x64]
push ecx
lea edx, [esp + 0x38]
push edx
push eax
mov eax, dword [esp + 0x90]
push 1
push ebp
mov ecx, edi
call fcn.00501b10
add esp, 0x28
mov dword [esp + 0x14], eax
jmp 0x5025c1
test ecx, ecx
je case.0x502230.0
mov esi, dword [esp + 0x18]
call fcn.005008c0
mov ebx, dword [esp + 0x14]
mov esi, dword [esp + 0x1c]
mov dword [esp + 0x18], eax
jmp case.0x502230.0
mov eax, dword [esp + 0x24]
test eax, eax
je 0x50263c
cmp ebp, eax
jne 0x5025f3
lea eax, [ebp + 1]
mov dword [esp + 0x24], eax
jmp case.0x502230.0
cmp dword [esp + 0x2c], 0
jne 0x50263c
mov edx, dword [esp + 0x78]
mov ebx, dword [esp + 0x70]
lea ecx, [esp + 0x30]
push ecx
push edx
lea eax, [esp + 0x30]
push eax
push edi
lea ecx, [esp + 0x60]
push ecx
mov ecx, dword [esp + 0x38]
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x38]
push eax
mov eax, dword [esp + 0x34]
push ecx
mov ecx, ebp
mov dword [esp + 0x4c], ebp
call fcn.00501c00
mov ebx, dword [esp + 0x34]
add esp, 0x20
mov dword [esp + 0x18], eax
lea edx, [ebp + 1]
mov dword [esp + 0x3c], edx
mov dword [esp + 0x38], 0
mov esi, 3
jmp 0x502af5
movsx eax, al
add eax, 0xfffffff6
cmp eax, 0x34
ja case.0x502230.0
movzx eax, byte [eax + 0x502d14]
jmp dword [eax*4 + 0x502d04]
lea ecx, [ebp + 1]
mov dword [esp + 0x3c], ecx
jmp case.0x502230.0
dec ebp
mov esi, 2
jmp 0x502af5
mov dword [esp + 0x38], ebp
mov esi, 4
jmp 0x502af5
movsx eax, al
add eax, 0xfffffff6
cmp eax, 0x34
ja case.0x5026a9.11
movzx edx, byte [eax + 0x502d60]
jmp dword [edx*4 + 0x502d4c]
lea eax, [ebp + 1]
mov dword [esp + 0x34], eax
mov esi, 6
jmp 0x502af5
lea ecx, [ebp + 1]
mov dword [esp + 0x34], ecx
mov esi, 5
jmp 0x502af5
mov dword [esp + 0x34], ebp
mov esi, 7
jmp 0x502af5
cmp al, 0x22
jne case.0x502230.0
mov edx, dword [esp + 0x78]
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
mov ebx, dword [esp + 0x34]
push edx
mov edx, dword [esp + 0x28]
push ebp
push eax
mov eax, dword [esp + 0x7c]
push ecx
mov ecx, dword [esp + 0x28]
push edx
push edi
push eax
mov eax, dword [esp + 0x4c]
mov esi, 2
mov dword [esp + 0x38], esi
call fcn.00501eb0
mov ebx, dword [esp + 0x30]
add esp, 0x1c
jmp case.0x502230.0
cmp al, 0x27
jne case.0x502230.0
mov ecx, dword [esp + 0x78]
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x3c]
mov ebx, dword [esp + 0x34]
push ecx
mov ecx, dword [esp + 0x28]
push ebp
push edx
mov edx, dword [esp + 0x7c]
push eax
mov eax, dword [esp + 0x40]
push ecx
mov ecx, dword [esp + 0x2c]
push edi
mov esi, 2
push edx
mov dword [esp + 0x38], esi
call fcn.00501eb0
mov ebx, dword [esp + 0x30]
add esp, 0x1c
jmp case.0x502230.0
movsx eax, al
add eax, 0xfffffff6
cmp eax, 0x34
ja case.0x502230.0
movzx eax, byte [eax + 0x502da4]
jmp dword [eax*4 + 0x502d98]
mov ecx, dword [esp + 0x78]
mov edx, dword [esp + 0x38]
mov eax, dword [esp + 0x3c]
mov ebx, dword [esp + 0x34]
push ecx
mov ecx, dword [esp + 0x28]
push ebp
push edx
mov edx, dword [esp + 0x7c]
push eax
mov eax, dword [esp + 0x40]
push ecx
mov ecx, dword [esp + 0x2c]
push edi
push edx
call fcn.00501eb0
mov ebx, dword [esp + 0x30]
add esp, 0x1c
mov esi, 3
jmp 0x502af5
mov eax, dword [esp + 0x78]
mov ecx, dword [esp + 0x38]
mov edx, dword [esp + 0x3c]
mov ebx, dword [esp + 0x34]
push eax
mov eax, dword [esp + 0x28]
push ebp
push ecx
mov ecx, dword [esp + 0x7c]
push edx
push eax
mov eax, dword [esp + 0x44]
push edi
push ecx
mov ecx, dword [esp + 0x34]
call fcn.00501eb0
mov ebx, dword [esp + 0x30]
add esp, 0x1c
dec ebp
mov esi, 2
jmp 0x502af5
cmp al, 0x3e
jne case.0x502230.0
mov eax, dword [esp + 0x24]
test eax, eax
je 0x5023db
mov esi, ebp
sub esi, eax
cmp esi, 1
jne 0x50284e
mov al, byte [eax]
cmp al, 0x62
je 0x502915
cmp al, 0x69
je 0x502915
cmp al, 0x75
je 0x502915
cmp al, 0x61
jne 0x5023db
jmp 0x502915
cmp esi, 6
jne 0x50286e
mov edx, dword [esp + 0x24]
push esi
push str.strike
push edx
call fcn.00505250
add esp, 0xc
test eax, eax
je 0x502915
cmp esi, 3
jne 0x50288e
mov eax, dword [esp + 0x24]
push esi
push 0x570e88
push eax
call fcn.00505250
add esp, 0xc
test eax, eax
je 0x502915
cmp esi, 4
jne 0x5028aa
mov ecx, dword [esp + 0x24]
push esi
push str.span
push ecx
call fcn.00505250
add esp, 0xc
test eax, eax
je 0x502915
cmp esi, 5
jne 0x5028c6
mov edx, dword [esp + 0x24]
push esi
push 0x570e94
push edx
call fcn.00505250
add esp, 0xc
test eax, eax
je 0x502915
cmp esi, 6
jne 0x5023db
mov eax, dword [esp + 0x24]
push esi
push str.center
push eax
call fcn.00505250
add esp, 0xc
test eax, eax
jne 0x5023db
mov ecx, dword [esp + 0x78]
mov edx, dword [esp + 0x70]
push ecx
push edx
push edi
lea eax, [esp + 0x5c]
push eax
xor esi, esi
push esi
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x34]
call fcn.005016f0
add esp, 0x14
mov dword [esp + 0x14], esi
mov dword [esp + 0x20], esi
mov esi, dword [esp + 0x18]
call fcn.005008c0
mov ebx, dword [esp + 0x14]
mov dword [esp + 0x18], eax
xor esi, esi
jmp 0x502af5
movsx eax, al
cmp eax, 0x3c
ja case.0x502230.0
movzx ecx, byte [eax + 0x502df0]
jmp dword [ecx*4 + 0x502ddc]
mov eax, dword [esp + 0x78]
push eax
lea edx, [ebp + 1]
lea ecx, [esp + 0x2c]
mov dword [esp + 0x28], edx
push ecx
lea edx, [esp + 0x58]
push edx
lea eax, [esp + 0x2c]
push eax
mov eax, dword [esp + 0x80]
push ebx
push 0
mov esi, 2
push ebp
mov ecx, edi
mov dword [esp + 0x48], 0
mov dword [esp + 0x38], esi
call fcn.00501b10
mov ebx, eax
add esp, 0x1c
mov dword [esp + 0x14], ebx
jmp case.0x502230.0
mov ecx, dword [esp + 0x78]
push ecx
lea edx, [esp + 0x2c]
push edx
lea eax, [esp + 0x58]
push eax
mov eax, dword [esp + 0x7c]
lea ecx, [esp + 0x2c]
push ecx
push ebx
push 0
push ebp
mov ecx, edi
call fcn.00501b10
mov edx, dword [esp + 0x34]
push edx
lea ecx, [esp + 0x40]
push ecx
push ebp
call fcn.00500a90
add esp, 0x28
mov esi, 9
jmp 0x502aef
mov edx, ebp
sub edx, dword [ebx]
cmp edx, 4
jne 0x5029fc
mov eax, dword [ebx]
push 5
push 0x570ea4
push eax
call fcn.00505250
add esp, 0xc
test eax, eax
jne 0x5029fc
mov esi, 0x570eac
jmp 0x502a92
mov ecx, ebp
sub ecx, dword [ebx]
cmp ecx, 3
jne 0x502a22
mov edx, dword [ebx]
push 4
push str.gt_
push edx
call fcn.00505250
add esp, 0xc
test eax, eax
jne 0x502a22
mov esi, 0x570eb8
jmp 0x502a92
mov eax, ebp
sub eax, dword [ebx]
cmp eax, 3
jne 0x502a48
mov ecx, dword [ebx]
push 4
push str.lt_
push ecx
call fcn.00505250
add esp, 0xc
test eax, eax
jne 0x502a48
mov esi, 0x570ec4
jmp 0x502a92
mov edx, ebp
sub edx, dword [ebx]
cmp edx, 5
jne 0x502a6e
mov eax, dword [ebx]
push 6
push str.nbsp_
push eax
call fcn.00505250
add esp, 0xc
test eax, eax
jne 0x502a6e
mov esi, 0x570ed0
jmp 0x502a92
mov ecx, ebp
sub ecx, dword [ebx]
cmp ecx, 5
jne 0x502aa7
mov edx, dword [ebx]
push 6
push str.quot_
push edx
call fcn.00505250
add esp, 0xc
test eax, eax
jne 0x502aa7
mov esi, 0x570edc
push 6
call fcn.00494940
add esp, 4
push esi
push eax
mov dword [ebx + 4], eax
call dword [sym.imp.KERNEL32.dll_lstrcpyW]
mov eax, dword [esp + 0x78]
push eax
lea ecx, [esp + 0x2c]
push ecx
lea edx, [esp + 0x58]
push edx
lea eax, [esp + 0x2c]
push eax
push ebx
push 0
lea ecx, [ebp + 1]
push ecx
jmp 0x502adc
mov edx, dword [esp + 0x78]
push edx
lea eax, [esp + 0x2c]
push eax
lea ecx, [esp + 0x58]
push ecx
lea edx, [esp + 0x2c]
push edx
push ebx
push 1
push ebp
mov eax, dword [esp + 0x8c]
mov ecx, edi
call fcn.00501b10
add esp, 0x1c
xor esi, esi
mov ebx, eax
mov dword [esp + 0x14], ebx
mov dword [esp + 0x1c], esi
inc ebp
cmp byte [esp + 0x13], 0
jne 0x502206
mov eax, dword [esp + 0x78]
mov ecx, dword [esp + 0x70]
push eax
push ecx
push edi
lea edx, [esp + 0x5c]
push edx
xor ebp, ebp
push ebp
lea ecx, [esp + 0x3c]
lea edx, [esp + 0x34]
call fcn.005016f0
mov eax, dword [esp + 0x58]
add esp, 0x14
push eax
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
mov eax, dword [esp + 0x28]
cmp eax, ebp
je 0x502b43
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov ecx, dword [esp + 0x40]
push ecx
call fcn.004934fd
mov esi, dword [esp + 0x1c]
add esp, 4
call fcn.005008c0
mov ebx, dword [esp + 0x70]
mov eax, dword [ebx + 0x20]
mov edi, dword [esp + 0x50]
cmp eax, ebp
je 0x502b89
mov ecx, dword [eax + 4]
cmp ecx, edi
mov esi, dword [eax + 8]
jle 0x502b74
mov edi, ecx
mov dword [ebx + 0x20], esi
push eax
mov dword [eax + 8], ebp
call fcn.004934fd
add esp, 4
mov eax, esi
cmp esi, ebp
jne 0x502b68
mov eax, dword [ebx + 0x24]
cmp eax, ebp
je 0x502bb1
mov ecx, dword [eax + 4]
cmp ecx, edi
mov esi, dword [eax + 8]
jle 0x502b9c
mov edi, ecx
mov dword [ebx + 0x24], esi
push eax
mov dword [eax + 8], ebp
call fcn.004934fd
add esp, 4
mov eax, esi
cmp esi, ebp
jne 0x502b90
mov eax, edi
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x5c
ret
mov edx, dword [esp + 0x44]
push edx
push edi
call dword [sym.imp.GDI32.dll_SelectObject]
mov eax, dword [esp + 0x28]
test eax, eax
je 0x502bd6
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
mov eax, dword [esp + 0x40]
push eax
call fcn.004934fd
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x5c
ret