Function at 0x401900
Capabilities:
Hide graphical window

Disassembly:
sub esp, 0x6ec
mov dword [esp + 4], 0
push ebx
push esi
mov esi, dword [esp + 0x6fc]
push edi
test esi, 0x80
setne al
mov byte [esp + 0x1b8], al
push ebp
test esi, 0x100
setne cl
mov ebx, dword [0x416088]
mov byte [esp + 0x10], cl
test esi, 0x200
setne dl
and esi, 0xfffffc7f
mov byte [esp + 0x11], dl
test ebx, ebx
jne 0x401a89
call dword [sym.imp.KERNEL32.dll_GetVersion]
push 0
cmp al, 4
sbb eax, eax
and eax, 0x10000
add eax, 0xa0000
mov dword [0x418634], eax
call dword [sym.imp.USER32.dll_GetDC]
mov ebx, eax
push 0xc
push ebx
mov edi, dword [sym.imp.GDI32.dll_GetDeviceCaps]
call edi
mov ebp, eax
push 0xe
push ebx
call edi
imul ebp, eax
mov dword [0x416088], ebp
cmp ebp, 0x18
jbe 0x4019a4
mov dword [0x416088], 0x18
mov eax, 1
mov cl, byte [0x416088]
shl eax, cl
mov dword [0x416088], eax
mov eax, 0x100
cmp dword [0x416088], eax
jae 0x4019c8
mov eax, dword [0x416088]
mov dword [0x418a88], eax
mov eax, dword [0x416088]
cmp eax, 0x100
jne 0x4019ea
push 0x18
push ebx
call edi
cdq
sub eax, edx
sar eax, 1
mov dword [0x418560], eax
jmp 0x4019f4
mov dword [0x418560], 0
mov edi, 0x418660
xor eax, eax
mov ecx, 0x10a
rep stosd dword es:[edi], eax
mov word [eax*2 + 0x418688], ax
inc eax
cmp eax, 0x100
jb 0x401a02
lea edi, [esp + 0x2fc]
xor eax, eax
mov word [esp + 0x2f8], 0x300
mov word [esp + 0x2fa], 0x100
mov ecx, 0x100
rep stosd dword es:[edi], eax
lea eax, [esp + 0x2ff]
mov byte [eax], 4
add eax, 4
lea ecx, [esp + 0x6ff]
cmp eax, ecx
jb 0x401a3d
lea eax, [esp + 0x2f8]
push 1
push eax
mov ebp, dword [sym.imp.GDI32.dll_CreatePalette]
call ebp
push eax
mov ebp, dword [sym.imp.GDI32.dll_SelectPalette]
push ebx
call ebp
mov edi, eax
push ebx
call dword [sym.imp.GDI32.dll_RealizePalette]
push 1
push edi
push ebx
call ebp
push eax
call dword [sym.imp.GDI32.dll_DeleteObject]
push ebx
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
push 0
call dword [sym.imp.USER32.dll_GetDC]
push eax
mov edi, eax
call dword [sym.imp.GDI32.dll_GetSystemPaletteUse]
cmp eax, 2
jne 0x401aab
mov dword [0x418638], 1
jmp 0x401ab5
mov eax, dword [0x418560]
mov dword [0x418638], eax
push edi
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
mov eax, dword [esp + 0x710]
test eax, eax
jne 0x401ad7
mov eax, dword [esp + 0x708]
mov dword [esp + 0x710], eax
mov eax, dword [esp + 0x714]
mov ebx, dword [esp + 0x70c]
test eax, eax
jne 0x401af0
mov dword [esp + 0x714], ebx
mov eax, dword [esp + 0x708]
mov ecx, dword [esp + 0x710]
cmp ecx, eax
jne 0x401b17
mov eax, dword [esp + 0x714]
cmp eax, ebx
jne 0x401b17
mov byte [esp + 0x80], 0
jmp 0x401b1f
mov byte [esp + 0x80], 1
mov eax, dword [esp + 0x710]
sub edx, edx
shl eax, 2
div dword [esp + 0x708]
test edx, edx
jne 0x401b4f
mov eax, dword [esp + 0x714]
sub edx, edx
shl eax, 2
div ebx
test edx, edx
jne 0x401b4f
mov byte [esp + 0x12], 0
jmp 0x401b54
mov byte [esp + 0x12], 1
mov ebp, 6
test esi, esi
je 0x401b60
lea ebp, [esi + 1]
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
lea eax, [ebp - 2]
dec ebp
cmp eax, 4
ja case.default.0x401b73
jmp dword [eax*4 + 0x402394]
mov eax, dword [esp + 0x708]
cmp eax, 0x140
ja case.default.0x401b73
cmp ebx, 0xf0
ja case.default.0x401b73
mov al, byte [esp + 0x80]
test al, al
je 0x401bd1
jmp case.default.0x401b73
mov eax, dword [esp + 0x708]
cmp eax, 0x140
ja case.default.0x401b73
cmp ebx, 0xc8
ja case.default.0x401b73
mov al, byte [esp + 0x80]
test al, al
jne case.default.0x401b73
call fcn.00402520
test al, al
jne 0x401cce
jmp case.default.0x401b73
mov eax, dword [0x416078]
test eax, eax
jne 0x401c11
mov eax, dword [0x416080]
test eax, eax
jne 0x401cce
push 0x416358
push 0x41636c
call edi
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x401cce
mov dword [esp + 0x14], 1
mov ebp, 5
jmp 0x401c25
mov byte [esp + 0x13], 0
mov eax, dword [0x416080]
test eax, eax
jne 0x401c33
call fcn.004023c0
mov eax, dword [0x416078]
test eax, eax
jne 0x401c61
mov eax, dword [0x416080]
cmp eax, 0x20
jae 0x401cce
test esi, esi
je 0x401b66
xor eax, eax
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x6ec
ret 0x18
mov eax, dword [0x416088]
cmp eax, 0x10000
ja 0x401cce
mov eax, dword [esp + 0x708]
mov ecx, dword [esp + 0x710]
add eax, eax
cmp eax, ecx
jne 0x401c93
lea eax, [ebx*2]
mov ecx, dword [esp + 0x714]
cmp eax, ecx
je 0x401cb0
mov eax, dword [esp + 0x708]
mov ecx, dword [esp + 0x710]
cmp ecx, eax
jne 0x401cce
mov eax, dword [esp + 0x714]
cmp eax, ebx
jne 0x401cce
mov al, byte [esp + 0x1bc]
test al, al
jne 0x401cce
mov byte [esp + 0x13], 1
mov eax, dword [0x41608c]
test eax, eax
jne 0x401cce
call fcn.004024d0
push 0x4a4
call fcn.00401000
mov esi, eax
test esi, esi
je 0x401c52
xor eax, eax
mov al, byte [esp + 0x80]
mov dword [esp + 0x80], eax
mov edi, esi
xor eax, eax
mov ecx, 0x129
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x708]
mov edx, dword [esp + 0x710]
mov dword [esi + 8], ebp
dec ebp
mov dword [esi + 0x10], eax
mov dword [esi + 0x14], ebx
mov eax, dword [esi + 0x10]
add eax, 7
and eax, 0xfffffff8
cmp ebp, 4
mov dword [esi + 0x18], eax
mov eax, dword [esp + 0x714]
mov ecx, dword [0x416088]
mov dword [esi + 0x28], ecx
mov dword [esi + 0x20], edx
mov dword [esi + 0x24], eax
mov ecx, dword [esp + 0x80]
mov dword [esi + 0x1c], ecx
mov dword [esi + 0x43c], 6
ja case.default.0x401d54
jmp dword [ebp*4 + 0x4023a8]
mov eax, dword [0x418a88]
mov dl, byte [esp + 0x12]
mov dword [esi + 0x2c], eax
mov ecx, dword [0x418638]
mov dword [esi + 0x34], ecx
mov ecx, dword [0x418638]
mov eax, dword [0x418a88]
sub eax, ecx
cmp dl, 1
mov dword [esi + 0x38], eax
sbb eax, eax
inc eax
mov dword [esi + 4], eax
mov ebp, dword [0x416078]
test ebp, ebp
je 0x401dc5
mov dword [0x418660], 0x28
mov dword [0x418668], 0xffffffff
mov word [0x41866c], 1
mov word [0x41866e], 8
mov dword [0x418670], 0
jmp 0x401dd0
push 0x418660
call dword [0x418558]
xor eax, eax
mov ecx, dword [0x418668]
test ecx, ecx
setge al
mov dword [esi], eax
mov eax, ebx
mov edx, dword [esi + 0x18]
mov ebp, dword [0x416078]
mov dword [0x418664], edx
imul eax, dword [0x418668]
mov dword [0x418668], eax
test ebp, ebp
je 0x401e22
push 0
call dword [sym.imp.USER32.dll_GetDC]
push eax
mov edi, eax
call dword [sym.imp.GDI32.dll_CreateCompatibleDC]
push edi
mov dword [esi + 0x45c], eax
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
jmp 0x401e2e
call dword [0x41862c]
mov dword [esi + 0x45c], eax
mov eax, dword [esi + 0x45c]
test eax, eax
jne 0x401e4e
mov eax, dword [esp + 0x14]
test eax, eax
je 0x401fd4
mov ebp, 4
jmp 0x401cf2
mov ecx, dword [0x416078]
lea ebp, [esi + 0x450]
lea edi, [esi + 0x448]
test ecx, ecx
je 0x401e79
push 0
push 0
push edi
push 1
push 0x418660
push eax
call dword [0x41607c]
jmp 0x401e86
push edi
push 0x418660
push eax
call dword [0x41855c]
mov dword [ebp], eax
mov eax, dword [ebp]
test eax, eax
je 0x401e9a
mov eax, dword [edi]
test eax, eax
jne 0x401fdf
mov eax, dword [esi + 0x45c]
push eax
call dword [sym.imp.GDI32.dll_DeleteDC]
mov eax, dword [esp + 0x14]
test eax, eax
je 0x4021db
mov ebp, 4
jmp 0x401cf2
mov dword [esi + 0x2c], 0x100
mov dword [esi + 0x34], 0
mov dword [esi + 0x38], 0x100
mov dword [esi + 4], 1
mov dword [esi + 0xc], 1
cmp ebx, 0xc8
ja 0x401fa9
mov dword [esi + 0x14], 0xcc
mov ebx, 0xcc
jmp 0x401fa9
mov dword [esi + 0x2c], 0x100
mov dword [esi + 0x34], 0
mov dword [esi + 0x38], 0x100
mov dword [esi + 4], 1
mov dword [esi + 0xc], 1
jmp 0x401fa9
mov dword [esi + 0x2c], 0x100
mov dword [esi + 0x34], 0
mov dword [esi + 0x38], 0x100
mov dword [esi + 4], 2
mov dword [esi + 0xc], 1
mov dword [esi + 0x10], 0x140
mov dword [esi + 0x14], 0xc8
mov eax, dword [0x418634]
push 0xfa00
mov dword [esi + 0x448], eax
call fcn.00401000
mov edi, eax
mov ecx, 0x3e80
mov dword [esi + 0x44c], eax
xor eax, eax
rep stosd dword es:[edi], eax
jmp case.default.0x401d54
mov eax, dword [0x418a88]
mov dword [esi + 0x2c], eax
mov ecx, dword [0x418638]
mov dword [esi + 0x34], ecx
mov ecx, dword [0x418638]
mov eax, dword [0x418a88]
sub eax, ecx
mov dword [esi + 0x38], eax
mov dword [esi + 4], 1
mov dword [esi], 1
mov eax, dword [esi + 0x18]
imul eax, ebx
push eax
call fcn.00401000
mov dword [esi + 0x448], eax
test eax, eax
jne case.default.0x401d54
push esi
call fcn.00401040
jmp 0x401c52
push esi
call fcn.00401040
jmp 0x401c52
mov eax, dword [esi + 0x450]
mov ecx, dword [esi + 0x45c]
push eax
push ecx
call dword [sym.imp.GDI32.dll_SelectObject]
mov dword [esi + 0x454], eax
mov ecx, dword [0x416074]
test ecx, ecx
je case.default.0x401d54
mov al, byte [esp + 0x13]
test al, al
je case.default.0x401d54
push 0
lea eax, [esi + 0x478]
push eax
push 0
call ecx
test eax, eax
jne case.default.0x401d54
lea edi, [esp + 0x80]
xor eax, eax
mov ecx, 0x4f
rep stosd dword es:[edi], eax
lea edi, [esp + 0x1bc]
mov ecx, 0x4f
rep stosd dword es:[edi], eax
mov eax, 0x13c
push 8
mov ebx, dword [esp + 0x704]
mov dword [esp + 0x84], eax
mov dword [esp + 0x1c0], eax
push ebx
mov eax, dword [esi + 0x478]
push eax
mov ebp, dword [eax]
call dword [ebp + 0x50]
test eax, eax
jne 0x4021c3
mov ecx, dword [esi + 0x478]
lea eax, [esp + 0x1bc]
lea edx, [esp + 0x80]
push eax
push edx
mov ebp, dword [ecx]
push ecx
call dword [ebp + 0x2c]
mov eax, dword [esp + 0x84]
test eax, 0x8000000
jne 0x4021c3
lea edi, [esp + 0x14]
xor eax, eax
mov ecx, 0x1b
rep stosd dword es:[edi], eax
mov dword [esp + 0x14], 0x6c
lea edi, [esi + 0x47c]
push 0
lea ecx, [esp + 0x18]
push edi
mov dword [esp + 0x20], 1
mov dword [esp + 0x84], 0x200
mov eax, dword [esi + 0x478]
push ecx
push eax
mov eax, dword [eax]
call dword [eax + 0x18]
test eax, eax
jne 0x4021c3
mov eax, dword [esi + 0x1c]
test eax, eax
jne 0x402105
lea ebp, [esi + 0x480]
mov dword [ebp], 1
jmp 0x40213a
mov al, byte [esp + 0x10]
test al, al
je 0x40211c
lea ebp, [esi + 0x480]
mov dword [ebp], 4
jmp 0x40213a
mov al, byte [esp + 0x11]
lea ebp, [esi + 0x480]
test al, al
je 0x402133
mov dword [ebp], 8
jmp 0x40213a
mov dword [ebp], 2
mov eax, dword [edi]
push eax
call fcn.004038f0
mov ecx, dword [ebp]
or ecx, eax
mov dword [ebp], ecx
cmp ecx, 0xffffffff
je 0x4021b5
mov eax, dword [edi]
push 0
lea ecx, [esp + 0x18]
push 1
push ecx
push 0
push eax
mov eax, dword [eax]
call dword [eax + 0x64]
cmp eax, 0x887601b3
je 0x4021b5
mov eax, dword [edi]
mov ecx, dword [esp + 0x38]
push ecx
push eax
mov eax, dword [eax]
call dword [eax + pe_nt_image_headers32]
push 0xfffffffffffffff4
push ebx
call dword [sym.imp.USER32.dll_GetClassLongA]
test eax, eax
jne 0x402193
push 0x7f00
push 0
call dword [sym.imp.USER32.dll_LoadCursorA]
push eax
mov eax, dword [edi]
push eax
call fcn.00403a10
mov dword [esi + 0x488], eax
mov eax, dword [ebp]
push eax
call sym.smackplw.exe__SmackBlitOpen_4
mov dword [esi + 0x484], eax
test eax, eax
jne 0x4021ed
mov eax, dword [edi]
push eax
mov ebp, dword [eax]
call dword [ebp + 8]
mov dword [edi], 0
mov eax, dword [esi + 0x478]
push eax
mov ebp, dword [eax]
call dword [ebp + 8]
mov dword [esi + 0x478], 0
jmp 0x4021ed
push esi
call fcn.00401040
jmp 0x401c52
mov ebx, dword [esp + 0x700]
mov eax, dword [esi + 0x38]
mov ecx, dword [esi + 0x34]
sub eax, ecx
mov dword [esi + 0x30], eax
mov edx, dword [esi + 4]
cmp edx, 2
je 0x402208
push 0
push esi
call fcn.00403730
mov eax, dword [esi + 0x28]
cmp eax, 0x100
ja 0x402273
push 0
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
lea eax, [esp + 0x2fc]
push eax
mov ebp, dword [sym.imp.GDI32.dll_GetSystemPaletteEntries]
xor eax, eax
mov ax, word [esi + 0x2c]
push eax
push 0
push edi
call ebp
push edi
push 0
call dword [sym.imp.USER32.dll_ReleaseDC]
xor eax, eax
mov ecx, dword [esi + 0x2c]
cmp ecx, eax
je 0x402273
lea ecx, [esi + 0x3e]
lea edi, [esp + 0x2fc]
mov dl, byte [edi]
add ecx, 4
add edi, 4
inc eax
mov byte [ecx - 4], dl
mov dl, byte [edi - 3]
mov byte [ecx - 5], dl
mov dl, byte [edi - 2]
mov byte [ecx - 6], dl
mov byte [ecx - 3], 0
cmp dword [esi + 0x2c], eax
ja 0x402252
mov dword [esi + 0x464], ebx
mov eax, dword [esi + 0xc]
test eax, eax
je 0x40238b
push 0
push 0xfffffffffffffffa
push ebx
call dword [sym.imp.USER32.dll_GetWindowLongA]
push eax
push 0
push ebx
push 0x20
push 0x20
push 0
push 0
push 0x80000000
push 0x416374
push 0x416378
push 0
call dword [sym.imp.USER32.dll_CreateWindowExA]
mov dword [esi + 0x470], eax
test eax, eax
jne 0x4022e3
mov eax, dword [esi + 4]
cmp eax, 1
jne 0x4022cc
mov eax, dword [esi + 0x448]
jmp 0x4022d2
mov eax, dword [esi + 0x44c]
push eax
call fcn.00401040
push esi
call fcn.00401040
jmp 0x401c52
push 0x4017d0
mov edi, dword [sym.imp.USER32.dll_SetWindowLongA]
push 0xfffffffffffffffc
mov dword [0x418bd0], esi
mov eax, dword [esi + 0x470]
push eax
call edi
push 0x401770
mov dword [esi + 0x46c], eax
push 0xfffffffffffffffc
mov ecx, dword [esi + 0x464]
push ecx
call edi
push esi
mov dword [esi + 0x468], eax
call fcn.00402580
add esp, 4
mov eax, dword [esi + 8]
dec eax
cmp eax, 1
push 0x418660
sbb eax, eax
push 0x428
and eax, 4
mov ecx, dword [esi + 0x470]
inc eax
or eax, 0xffff8ad0
shl eax, 0x10
add eax, 0x400
push eax
push 0
push ecx
call fcn.00401670
push 6
mov ecx, dword [esi + 0x464]
push ecx
call dword [sym.imp.USER32.dll_ShowWindow]
push 0x40
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 1
call edi
push eax
push 0
call edi
push eax
push 0
push 0
mov eax, dword [esi + 0x470]
push 0xffffffffffffffff
push eax
call dword [sym.imp.USER32.dll_SetWindowPos]
mov eax, esi
jmp 0x401c54