Function at 0x402cc0
Capabilities:
Link many functions at runtime

Disassembly:
sub esp, 0xb8
mov eax, dword [0x4b2a8c]
xor eax, esp
mov dword [esp + 0xb4], eax
mov eax, dword [esp + 0xbc]
push ebx
push ebp
push esi
push edi
push 0xfffffffffffffff5
mov dword [esp + 0x28], eax
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push str.Kernel32.dll
mov ebx, eax
mov byte [esp + 0x1b], 0
call dword [sym.imp.KERNEL32.dll_LoadLibraryA]
mov ebp, eax
mov dword [esp + 0x20], ebp
test ebp, ebp
je 0x402f5c
cmp dword [0x4b806c], 0
je 0x402dcb
mov edi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.SetCurrentConsoleFontEx
push ebp
call edi
push str.GetCurrentConsoleFontEx
push ebp
mov esi, eax
call edi
test esi, esi
je 0x402f55
test eax, eax
je 0x402f55
mov edi, dword [esp + 0x24]
push edi
push 0
push ebx
call esi
test eax, eax
je 0x402f55
lea esi, [esp + 0x68]
call fcn.00402ae0
test al, al
je 0x402f55
lea ecx, [esp + 0x7c]
lea eax, [edi + 0x14]
lea ebx, [ebx]
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x402d96
test dx, dx
je 0x402d92
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x402d96
add eax, 4
add ecx, 4
test dx, dx
jne 0x402d70
xor eax, eax
jmp 0x402d9b
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
jne 0x402f55
mov cx, word [edi + 8]
cmp cx, word [esp + 0x70]
jne 0x402f55
mov dx, word [edi + 0xa]
cmp dx, word [esp + 0x72]
jne 0x402f55
mov byte [esp + 0x17], 1
jmp 0x402f55
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
push str.GetConsoleFontInfo
push ebp
call esi
push str.GetNumberOfConsoleFonts
push ebp
mov edi, eax
call esi
push str.GetConsoleFontSize
push ebp
mov dword [esp + 0x20], eax
call esi
push str.SetConsoleFont
push ebp
mov dword [esp + 0x38], eax
call esi
push str.GetCurrentConsoleFont
push ebp
mov dword [esp + 0x24], eax
call esi
mov dword [esp + 0x28], eax
test edi, edi
je 0x402f55
mov eax, dword [esp + 0x18]
test eax, eax
je 0x402f55
cmp dword [esp + 0x1c], 0
je 0x402f55
call eax
mov ebp, eax
test ebp, ebp
je 0x402f51
lea eax, [esp + 0x40]
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetConsoleScreenBufferInfo]
movsx ecx, word [esp + 0x4a]
movsx eax, word [esp + 0x4e]
movsx edx, word [esp + 0x4c]
sub eax, ecx
inc eax
mov dword [esp + 0x18], eax
movsx eax, word [esp + 0x50]
sub eax, edx
inc eax
mov dword [esp + 0x2c], eax
lea eax, [ebp*8]
push eax
call fcn.00483bad
add esp, 4
mov esi, eax
push esi
push ebp
push 0
push ebx
mov dword [esp + 0x44], esi
call edi
xor edi, edi
test ebp, ebp
jbe 0x402f44
add esi, 4
mov edi, edi
mov ecx, dword [esi - 4]
push ecx
push ebx
call dword [esp + 0x38]
mov dword [esi], eax
mov dx, ax
mov eax, dword [esp + 0x24]
cmp dx, word [eax + 8]
jne 0x402f31
mov cx, word [esi + 2]
cmp cx, word [eax + 0xa]
jne 0x402f31
mov edx, dword [esi - 4]
push edx
push ebx
call dword [esp + 0x24]
test eax, eax
je 0x402f31
cmp dword [0x4b8004], 0
je 0x402ef7
mov eax, dword [esp + 0x28]
test eax, eax
je 0x402ef7
lea ecx, [esp + 0x38]
push ecx
push 0
push ebx
call eax
test eax, eax
je 0x402f31
mov dx, word [esi]
cmp dx, word [esp + 0x3c]
jne 0x402f31
mov ax, word [esi + 2]
cmp ax, word [esp + 0x3e]
jmp 0x402f2f
push 0xa
call dword [sym.imp.KERNEL32.dll_Sleep]
lea ecx, [esp + 0x58]
push ecx
call fcn.00402a00
push eax
call dword [sym.imp.USER32.dll_GetClientRect]
test eax, eax
je 0x402f31
movsx edx, word [esi]
imul edx, dword [esp + 0x18]
cmp edx, dword [esp + 0x60]
jne 0x402f31
movsx eax, word [esi + 2]
imul eax, dword [esp + 0x2c]
cmp eax, dword [esp + 0x64]
je 0x402f3f
inc edi
add esi, 8
cmp edi, ebp
jb 0x402e90
jmp 0x402f44
mov byte [esp + 0x17], 1
mov ecx, dword [esp + 0x34]
push ecx
call fcn.004838e2
add esp, 4
mov ebp, dword [esp + 0x20]
push ebp
call dword [sym.imp.KERNEL32.dll_FreeLibrary]
mov ecx, dword [esp + 0xc4]
mov al, byte [esp + 0x17]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
mov byte [0x26112b8], 1
call fcn.00482caa
add esp, 0xb8
ret