Function at 0xaf5fd0
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x18c
mov esi, dword [ebp + 0xc]
mov ebx, dword [ebp + 8]
mov edi, dword [ebp + 0x18]
mov dword [0x1a528c8], 1
mov ecx, dword [esi + 0x1c]
test ecx, ecx
je 0xaf6007
mov dword [esp + 4], esi
mov dword [esp], ebx
call dword [ebx + 0x60]
mov dword [esi + 0x1c], 0
mov eax, dword [ebx + 0x2ac]
mov eax, dword [eax + 4]
test eax, eax
je 0xaf602c
mov edx, dword [eax]
mov dword [esp], eax
call dword [edx + 8]
mov eax, dword [ebx + 0x2ac]
mov dword [eax + 4], 0
sub esp, 4
mov eax, dword [esi]
mov edx, eax
and edx, 0x80000002
cmp edx, 0x80000002
je 0xaf67f3
test al, 2
jne 0xaf6390
test byte [ebp + 0x1c], 2
je 0xaf61e0
mov eax, dword [esi + 4]
movzx eax, byte [eax + 4]
cmp eax, edi
je 0xaf731c
lea eax, [edi - 0xf]
cmp eax, 0x11
ja 0xaf61d0
mov edx, dword [eax*4 + 0x125a2e0]
mov ecx, dword [eax*4 + 0x125a340]
mov eax, dword [eax*4 + 0x125a3a0]
mov dword [esp + 0x1c], 0
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], ecx
mov dword [esp + 0x10], edx
mov dword [esp + 0xc], edi
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp], 0
call fcn.00ae2f80
test eax, eax
mov dword [ebp - 0x14c], eax
je 0xaf6f38
mov eax, dword [ebp - 0x14c]
mov edx, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0x14c]
mov eax, dword [eax + 8]
mov edx, dword [edx + 0xc]
mov dword [ecx], 0
mov dword [ebp - 0x15c], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x164], edx
mov edx, dword [ebp + 0x14]
mov dword [ecx + 8], eax
mov dword [ecx + 0xc], edx
mov dword [esp], ecx
call fcn.00ae16f0
mov edx, dword [ebp + 0x1c]
mov ecx, dword [ebp - 0x14c]
test edx, edx
mov word [ecx + 0x10], ax
js 0xaf6812
mov edx, dword [sym.imp.USER32.dll_GetWindowLongA]
mov eax, dword [0x1a528ac]
mov dword [esp + 4], 0xfffffff0
mov dword [ebp - 0x160], edx
mov dword [esp], eax
call edx
mov ecx, dword [ebp - 0x14c]
mov edx, dword [ecx]
sub esp, 8
test edx, edx
js 0xaf67e0
test byte [ebp + 0x1c], 0x20
je 0xaf63a0
mov esi, eax
mov eax, dword [ebp - 0x14c]
or edx, 0x20
and esi, 0xfe30ffff
or esi, 0x80000000
mov dword [eax], edx
mov eax, dword [0x1a528ac]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_IsZoomed]
mov edx, esi
or edx, 0x1000000
sub esp, 4
test eax, eax
cmovne esi, edx
mov eax, dword [0x1a528dc]
test eax, eax
je 0xaf66c8
mov dword [0x1a528c8], 0
mov dword [esp], ebx
call fcn.00b0bc00
test eax, eax
js 0xaf67c1
mov eax, dword [ebp - 0x14c]
or dword [eax], 2
mov eax, dword [ebp - 0x14c]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
xor eax, eax
xor ecx, ecx
xor edx, edx
jmp 0xaf6084
mov edx, dword [sym.imp.USER32.dll_GetWindowLongA]
mov eax, dword [0x1a528ac]
mov dword [esp + 4], 0xfffffff0
mov dword [ebp - 0x160], edx
mov dword [esp], eax
call edx
mov edx, dword [ebp + 0x1c]
sub esp, 8
test edx, edx
js 0xaf6922
test byte [ebp + 0x1c], 0x20
jne 0xaf63d0
and eax, 0x7efaffff
mov edx, eax
or eax, 0xcf0000
or edx, 0xca0000
test byte [ebp + 0x1c], 0x10
cmovne edx, eax
mov eax, dword [0x1a528ac]
mov dword [ebp - 0x16c], edx
mov dword [esp], eax
call dword [sym.imp.USER32.dll_IsZoomed]
mov edx, dword [ebp - 0x16c]
mov ecx, edx
or ecx, 0x1000000
sub esp, 4
test eax, eax
cmovne edx, ecx
mov eax, dword [0x1a528dc]
test eax, eax
je 0xaf6900
mov edx, dword [ebx + 0x2ac]
mov eax, dword [ebp + 0x1c]
mov edx, dword [edx]
sar eax, 0x1f
and eax, 0xb
add eax, 8
mov ecx, dword [edx]
mov dword [esp + 8], eax
mov eax, dword [0x1a528ac]
mov dword [esp], edx
mov dword [esp + 4], eax
call dword [ecx + 0x50]
sub esp, 0xc
test eax, eax
jne 0xaf727c
mov ecx, dword [ebp + 0x1c]
test ecx, ecx
js 0xaf6935
mov dword [ebp - 0x16c], eax
mov dword [esp + 4], 0
mov dword [esp], ebx
call fcn.00b0e8d0
mov eax, ebx
call fcn.00af5ea0
mov edx, dword [ebp - 0x16c]
lea eax, [ebp - 0xa0]
mov edi, eax
mov ecx, 0x1b
mov dword [ebp - 0x14c], eax
mov eax, edx
rep stosd dword es:[edi], eax
mov dword [ebp - 0xa0], 0x6c
mov dword [ebp - 0x9c], 1
and dword [ebp + 0x1c], 0xbfffffff
mov dword [ebp - 0x38], 0x4200
mov edx, dword [ebp + 0x1c]
and edx, 0x40000000
mov dword [ebp - 0x15c], edx
je 0xaf632d
mov dword [ebp - 0x9c], 0x21
mov dword [ebp - 0x38], 0x4218
mov dword [ebp - 0x8c], 1
mov eax, dword [ebx + 0x2ac]
lea edi, [ebp - 0x1c]
mov ecx, dword [ebp - 0x14c]
mov eax, dword [eax]
mov edx, dword [eax]
mov dword [esp + 0xc], 0
mov dword [esp + 8], edi
mov dword [esp + 4], ecx
mov dword [esp], eax
call dword [edx + 0x18]
sub esp, 0x10
test eax, eax
je 0xaf6429
mov edx, dword [ebp - 0x15c]
test edx, edx
jne 0xaf63e3
mov dword [esp + 4], eax
mov dword [esp], str.DirectDraw2::CreateSurface_PRIMARY_
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov dword [esp], ebx
call fcn.00b0b960
jmp 0xaf604a
and eax, 0x7efaffff
mov esi, eax
or esi, 0xca0000
test byte [ebp + 0x1c], 0x10
je 0xaf616d
mov ecx, dword [ebp - 0x14c]
mov esi, eax
or edx, 0x10
or esi, 0xcf0000
mov dword [ecx], edx
jmp 0xaf616d
mov edx, eax
and edx, 0xfe30ffff
or edx, 0x80000000
jmp 0xaf622f
mov eax, dword [ebx + 0x2ac]
mov ecx, dword [ebp - 0x14c]
and dword [ebp - 0x9c], 0xffffffdf
and dword [ebp - 0x38], 0xffffffe7
mov edx, dword [eax]
mov dword [ebp - 0x8c], 0
mov eax, dword [edx]
mov dword [esp + 0xc], 0
mov dword [esp + 8], edi
mov dword [esp + 4], ecx
mov dword [esp], edx
call dword [eax + 0x18]
sub esp, 0x10
test eax, eax
jne 0xaf636b
mov eax, dword [ebp - 0x1c]
mov ecx, dword [ebx + 0x2ac]
mov edx, dword [eax]
add ecx, 4
mov dword [esp + 8], ecx
mov dword [esp + 4], 0x14ce17c
mov dword [esp], eax
call dword [edx]
sub esp, 0xc
test eax, eax
mov dword [ebp - 0x15c], eax
jne 0xaf7213
mov eax, dword [ebp - 0x1c]
mov edx, dword [eax]
mov dword [esp], eax
call dword [edx + 8]
mov eax, dword [ebp - 0x15c]
mov ecx, 0x1b
mov edi, dword [ebp - 0x14c]
rep stosd dword es:[edi], eax
mov ecx, dword [ebp - 0x14c]
sub esp, 4
mov dword [ebp - 0xa0], 0x6c
mov eax, dword [ebx + 0x2ac]
mov dword [ebp - 0x9c], 0x1001
mov eax, dword [eax + 4]
mov edx, dword [eax]
mov dword [esp + 4], ecx
mov dword [esp], eax
call dword [edx + 0x58]
sub esp, 8
test eax, eax
jne 0xaf7368
test byte [ebp - 0x54], 0x40
je 0xaf73e4
mov edx, dword [ebx + 0x2ac]
mov eax, dword [edx + 0xc]
test eax, eax
je 0xaf64e3
mov edx, dword [eax]
mov dword [esp], eax
call dword [edx + 8]
mov edx, dword [ebx + 0x2ac]
mov dword [edx + 0xc], 0
sub esp, 4
cmp dword [ebp - 0x4c], 8
je 0xaf6ba2
mov eax, dword [ebp + 0x10]
cmp dword [esi + 8], eax
jne 0xaf6501
mov edx, dword [ebp + 0x14]
cmp dword [esi + 0xc], edx
je 0xaf7183
mov dword [esp], esi
call fcn.00ae2ea0
mov eax, dword [ebp - 0x40]
mov dword [esp + 0x1c], 0
mov dword [esp + 8], 0
mov dword [esp + 4], 0
mov dword [esp + 0x18], eax
mov eax, dword [ebp - 0x44]
mov dword [esp], 0
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x48]
mov dword [esp + 0x10], eax
mov eax, dword [ebp - 0x4c]
mov dword [esp + 0xc], eax
call fcn.00ae2f80
test eax, eax
mov dword [ebp - 0x14c], eax
je 0xaf6f38
mov ecx, dword [ebp - 0x14c]
mov eax, dword [ebp - 0x14c]
mov edx, dword [ebp - 0x14c]
mov ecx, dword [ecx + 8]
mov eax, dword [eax + 0xc]
mov word [edx + 0x10], 0
mov dword [ebp - 0x164], ecx
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0x168], eax
mov eax, dword [ebp + 0x14]
mov dword [edx + 8], ecx
mov dword [edx + 0xc], eax
mov ecx, dword [ebp + 0x1c]
mov edx, dword [ebp - 0x14c]
test ecx, ecx
mov dword [edx], 0
js 0xaf6d20
mov eax, dword [edx + 0x14]
test eax, eax
je 0xaf7387
mov edx, dword [ebp + 0x1c]
xor eax, eax
and edx, 0x30
cmp edx, 0x10
je 0xaf6f49
test byte [ebp + 0x1c], 0x20
jne 0xaf6b90
mov edx, dword [ebp - 0x14c]
xor ecx, ecx
mov eax, dword [edx]
test byte [ebp - 0x38], 0x10
je 0xaf65e7
mov edx, dword [ebp - 0x14c]
or eax, 0x40000000
mov dword [edx], eax
mov edx, dword [ebp - 0x14c]
and eax, 1
lea edi, [ebx + 0x2ac]
mov dword [esp], eax
mov eax, edi
call fcn.00af5880
test eax, eax
js 0xaf73ff
mov edi, dword [ebp + 0x1c]
test edi, edi
js 0xaf6f04
mov edx, dword [ebx + 0x2ac]
mov dword [ebx + 0x20], 0xaf3fc0
mov eax, dword [edx + 8]
test eax, eax
je 0xaf7232
mov edx, dword [eax]
mov ecx, dword [0x1a528ac]
mov dword [esp + 4], 0
mov dword [esp], eax
mov dword [esp + 8], ecx
call dword [edx + 0x20]
sub esp, 0xc
test eax, eax
jne 0xaf6f5f
mov edx, dword [ebx + 0x2ac]
mov eax, dword [edx + 4]
mov edx, dword [edx + 8]
mov ecx, dword [eax]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [ecx + 0x70]
sub esp, 8
test eax, eax
jne 0xaf7327
mov ebx, dword [0x1a528dc]
test ebx, ebx
je 0xaf6fa0
mov eax, dword [0x1a528ac]
mov dword [esp + 4], 5
mov dword [esp], eax
call dword [sym.imp.USER32.dll_ShowWindow]
mov eax, dword [0x1a528ac]
sub esp, 8
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetForegroundWindow]
mov dword [0x1a528c8], 0
sub esp, 4
call fcn.00b0a660
mov eax, dword [ebp - 0x14c]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov eax, dword [0x1a528ac]
mov dword [esp + 8], esi
mov dword [esp + 4], 0xfffffff0
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
mov edi, dword [0x1a528dc]
sub esp, 0xc
test edi, edi
jne 0xaf6198
mov eax, dword [0x1a528ac]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_IsZoomed]
sub esp, 4
test eax, eax
jne 0xaf6198
mov edx, dword [ebp - 0x14c]
mov eax, dword [edx + 8]
cmp eax, dword [ebp - 0x15c]
je 0xaf6d62
mov dword [esp], str.SDL_VIDEO_WINDOW_POS
call fcn.00ae6ae0
mov dword [esp], str.SDL_VIDEO_CENTERED
mov dword [ebp - 0x154], eax
call fcn.00ae6ae0
mov esi, dword [ebp - 0x154]
test esi, esi
mov dword [ebp - 0x164], eax
je 0xaf71ea
lea eax, [ebp - 0x20]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x24]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x154]
mov dword [esp + 4], 0x125a0fb
mov dword [esp], eax
call sub.msvcrt.dll_sscanf
cmp eax, 2
je 0xaf6ee2
mov edx, dword [0x1a528c0]
mov ecx, dword [0x1a528c4]
mov dword [ebp - 0x15c], edx
mov dword [ebp - 0x158], ecx
mov esi, dword [ebp - 0x154]
mov edi, str.center
mov ecx, 7
repe cmpsb byte [esi], byte es:[edi]
je 0xaf7166
mov ecx, dword [ebp - 0x14c]
mov eax, dword [ecx + 8]
mov edx, dword [ecx + 0xc]
jmp 0xaf6da0
mov dword [ebp - 0x14c], 0
mov eax, dword [ebp - 0x14c]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov esi, eax
and esi, 0xfe30ffff
or esi, 0x80000000
jmp 0xaf618b
mov dword [esp + 4], 0
mov dword [esp], 0
call dword [sym.imp.USER32.dll_ChangeDisplaySettingsA]
mov eax, dword [esi]
sub esp, 8
jmp 0xaf6042
lea edx, [ebp - 0x13c]
xor eax, eax
mov ecx, 0x27
mov edi, edx
rep stosd dword es:[edi], eax
mov ecx, dword [ebp - 0x14c]
mov word [ebp - 0x118], 0x9c
mov eax, dword [ecx + 4]
mov ecx, dword [ebp + 0x14]
movzx eax, byte [eax + 4]
mov dword [ebp - 0xcc], ecx
mov dword [ebp - 0x114], 0x1c0000
mov dword [ebp - 0xd4], eax
mov eax, dword [ebp + 0x10]
cmp eax, dword [0x1abac4c]
mov dword [ebp - 0xd0], eax
jg 0xaf6880
cmp ecx, dword [0x1abac50]
jg 0xaf6880
mov eax, dword [0x1abac58]
mov dword [ebp - 0x114], 0x5c0000
mov dword [ebp - 0xc4], eax
mov esi, dword [sym.imp.USER32.dll_ChangeDisplaySettingsA]
mov dword [esp], edx
mov dword [ebp - 0x16c], edx
mov dword [esp + 4], 4
call esi
mov edx, dword [ebp - 0x16c]
sub esp, 8
test eax, eax
je 0xaf68e0
mov eax, dword [ebp - 0x114]
test eax, 0x400000
je 0xaf6119
and eax, 0xffbfffff
mov dword [esp], edx
mov dword [ebp - 0x114], eax
mov dword [esp + 4], 4
call esi
mov edx, dword [ebp - 0x16c]
sub esp, 8
test eax, eax
jne 0xaf6119
mov eax, dword [ebp - 0x14c]
mov edi, 0x1abaca0
mov ecx, 0x27
mov esi, edx
or dword [eax], 0x80000000
rep movsd dword es:[edi], dword [esi]
jmp 0xaf6119
mov eax, dword [0x1a528ac]
mov dword [esp + 8], edx
mov dword [esp + 4], 0xfffffff0
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetWindowLongA]
sub esp, 0xc
jmp 0xaf6266
mov edx, eax
and edx, 0xfe30ffff
or edx, 0x80000000
jmp 0xaf6259
mov edx, dword [sym.imp.USER32.dll_GetSystemMetrics]
mov dword [ebp - 0x34], 0
mov dword [ebp - 0x30], 0
mov dword [esp], 0
mov dword [ebp - 0x16c], edx
call edx
mov edx, dword [ebp - 0x16c]
sub esp, 4
mov dword [ebp - 0x2c], eax
mov dword [esp], 1
call edx
mov dword [ebp - 0x28], eax
mov eax, dword [0x1a528ac]
sub esp, 4
mov dword [esp], eax
call dword [sym.imp.USER32.dll_GetMenu]
mov edx, eax
mov eax, dword [0x1a528ac]
sub esp, 4
mov dword [ebp - 0x16c], edx
mov dword [esp + 4], 0xfffffff0
mov dword [esp], eax
call dword [ebp - 0x160]
mov edx, dword [ebp - 0x16c]
sub esp, 8
test edx, edx
setne dl
movzx edx, dl
mov dword [esp + 4], eax
lea eax, [ebp - 0x34]
mov dword [esp + 8], edx
mov dword [esp + 0xc], 0
mov dword [esp], eax
call dword [sym.imp.USER32.dll_AdjustWindowRectEx]
mov edx, dword [ebp - 0x30]
mov eax, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x34]
sub eax, edx
sub esp, 0x10
mov dword [esp + 0x14], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp + 0xc], edx
mov dword [esp + 8], ecx
mov dword [esp + 0x18], 0x100
sub eax, ecx
mov dword [esp + 0x10], eax
mov eax, dword [0x1a528ac]
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetWindowPos]
mov eax, dword [0x1a528ac]
sub esp, 0x1c
mov dword [esp + 4], 5
mov dword [esp], eax
call dword [sym.imp.USER32.dll_ShowWindow]
sub esp, 8
jmp 0xaf6a48
mov dword [esp], edx
call dword [sym.imp.USER32.dll_SetForegroundWindow]
sub esp, 4
mov dword [esp], 0x64
call fcn.00aea2d0
call dword [sym.imp.USER32.dll_GetForegroundWindow]
mov edx, dword [0x1a528ac]
cmp eax, edx
jne 0xaf6a30
test edi, edi
lea eax, [edi + 7]
cmovns eax, edi
xor ecx, ecx
sar eax, 3
mov eax, dword [eax*4 + 0x1a4e284]
test eax, eax
je 0xaf6a94
mov ecx, dword [ebp + 0x10]
jmp 0xaf6a80
mov eax, dword [eax + 0xc]
test eax, eax
je 0xaf6d14
movzx edx, word [eax + 4]
cmp edx, ecx
jne 0xaf6a75
movzx edx, word [eax + 6]
cmp edx, dword [ebp + 0x14]
jne 0xaf6a75
mov ecx, dword [eax + 8]
mov eax, dword [ebx + 0x2ac]
mov eax, dword [eax]
mov edx, dword [eax]
mov dword [esp + 0x10], ecx
mov ecx, dword [ebp + 0x14]
mov dword [esp + 0x14], 0
mov dword [esp + 0xc], edi
mov dword [esp], eax
mov dword [esp + 8], ecx
mov ecx, dword [ebp + 0x10]
mov dword [esp + 4], ecx
call dword [edx + 0x54]
sub esp, 0x18
test eax, eax
je 0xaf6b37
mov eax, dword [ebx + 0x2ac]
mov ecx, dword [ebp + 0x14]
mov edx, dword [eax]
mov eax, dword [edx]
mov dword [esp + 8], ecx
mov ecx, dword [ebp + 0x10]
mov dword [esp + 0x14], 0
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], edi
mov dword [esp + 4], ecx
mov dword [esp], edx
call dword [eax + 0x54]
sub esp, 0x18
test eax, eax
je 0xaf6b37
mov eax, dword [ebp + 0x1c]
mov edx, dword [ebp + 0x10]
mov dword [esp + 0x10], edi
mov dword [esp + 4], esi
and eax, 0x7fffffff
mov dword [esp + 0x14], eax
mov eax, dword [ebp + 0x14]
mov dword [esp + 8], edx
mov dword [esp], ebx
mov dword [esp + 0xc], eax
call fcn.00af5fd0
mov dword [ebp - 0x14c], eax
jmp 0xaf61bb
mov dword [esp + 4], 1
mov dword [esp], ebx
call fcn.00b0e8d0
mov eax, ebx
call fcn.00af5ea0
lea ecx, [ebp - 0xa0]
xor eax, eax
mov dword [ebp - 0x14c], ecx
mov edi, dword [ebp - 0x14c]
mov ecx, 0x1b
rep stosd dword es:[edi], eax
mov dword [ebp - 0xa0], 0x6c
mov dword [ebp - 0x9c], 1
mov dword [ebp - 0x38], 0x4200
jmp 0xaf6301
mov ecx, dword [ebp - 0x14c]
or eax, 0x20
mov dword [ecx], eax
xor ecx, ecx
jmp 0xaf65d4
mov edi, dword [ebp + 0x1c]
xor eax, eax
test edi, edi
jns 0xaf6c6d
xor ecx, ecx
jmp 0xaf6bb9
mov edx, dword [ebx + 0x2ac]
lea eax, [ecx + 4]
add ecx, 1
mov byte [edx + eax*4 + 3], 5
mov edx, dword [ebx + 0x2ac]
cmp ecx, 0x100
mov byte [edx + eax*4], 0
mov edx, dword [ebx + 0x2ac]
mov byte [edx + eax*4 + 1], 0
mov edx, dword [ebx + 0x2ac]
mov byte [edx + eax*4 + 2], 0
jne 0xaf6bb3
mov eax, dword [ebx + 0x2ac]
mov edx, dword [eax]
lea ecx, [eax + 0xc]
add eax, 0x10
mov edi, dword [edx]
mov dword [esp + 0x10], 0
mov dword [esp + 0xc], ecx
mov dword [esp + 8], eax
mov dword [esp + 4], 0x44
mov dword [esp], edx
call dword [edi + 0x14]
sub esp, 0x14
test eax, eax
jne 0xaf7428
mov edx, dword [ebx + 0x2ac]
mov eax, dword [edx + 4]
mov edx, dword [edx + 0xc]
mov ecx, dword [eax]
mov dword [esp + 4], edx
mov dword [esp], eax
call dword [ecx + 0x7c]
sub esp, 8
test eax, eax
je 0xaf64ed
mov dword [esp + 4], eax
mov dword [esp], str.DirectDrawSurface3::SetPalette
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov edx, dword [ebx + 0x2ac]
lea ecx, [eax + 4]
mov byte [edx + ecx*4 + 3], 2
mov edx, dword [ebx + 0x2ac]
mov byte [edx + ecx*4], al
mov edx, dword [ebx + 0x2ac]
add eax, 1
cmp eax, 0xa
mov byte [edx + ecx*4 + 1], 0
mov edx, dword [ebx + 0x2ac]
mov byte [edx + ecx*4 + 2], 0
jne 0xaf6c67
lea esi, [esi]
mov ecx, dword [ebx + 0x2ac]
lea edx, [eax + 4]
add eax, 1
cmp eax, 0xf6
mov byte [ecx + edx*4 + 3], 4
mov ecx, dword [ebx + 0x2ac]
mov byte [ecx + edx*4], 0
mov ecx, dword [ebx + 0x2ac]
mov byte [ecx + edx*4 + 1], 0
mov ecx, dword [ebx + 0x2ac]
mov byte [ecx + edx*4 + 2], 0
jne 0xaf6ca0
mov ecx, dword [ebx + 0x2ac]
lea edx, [eax + 4]
mov byte [ecx + edx*4 + 3], 2
mov ecx, dword [ebx + 0x2ac]
mov byte [ecx + edx*4], al
mov ecx, dword [ebx + 0x2ac]
add eax, 1
cmp eax, 0x100
mov byte [ecx + edx*4 + 1], 0
mov ecx, dword [ebx + 0x2ac]
mov byte [ecx + edx*4 + 2], 0
jne 0xaf6cd8
jmp 0xaf6bec
xor ecx, ecx
jmp 0xaf6a94
mov eax, dword [ebp - 0x14c]
mov edx, dword [eax + 0x14]
mov eax, 1
test edx, edx
je 0xaf6d4c
mov dword [esp], edx
call fcn.0108ed00
mov edx, dword [ebp - 0x14c]
mov eax, dword [edx]
mov dword [edx + 0x14], 0
or eax, 1
mov edx, dword [ebx + 0x2ac]
mov ecx, dword [edx + 4]
mov edx, dword [ebp - 0x14c]
mov dword [edx], eax
jmp 0xaf65d4
mov edx, dword [edx + 0xc]
cmp edx, dword [ebp - 0x164]
jne 0xaf6721
mov ecx, dword [0x1a528c0]
mov dword [ebp - 0x164], 0
mov dword [ebp - 0x154], 0
mov dword [ebp - 0x15c], ecx
mov ecx, dword [0x1a528c4]
mov dword [ebp - 0x158], ecx
lea esi, [esi]
mov ecx, dword [ebp - 0x15c]
add eax, dword [ebp - 0x15c]
mov dword [ebp - 0x34], ecx
mov ecx, dword [ebp - 0x158]
mov dword [ebp - 0x2c], eax
mov eax, dword [0x1a528ac]
add edx, ecx
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x28], edx
mov dword [esp], eax
call dword [sym.imp.USER32.dll_GetMenu]
mov esi, eax
mov eax, dword [0x1a528ac]
sub esp, 4
mov dword [esp + 4], 0xfffffff0
mov dword [esp], eax
call dword [ebp - 0x160]
xor edx, edx
sub esp, 8
test esi, esi
setne dl
mov dword [esp + 4], eax
lea eax, [ebp - 0x34]
mov dword [esp + 8], edx
mov dword [esp + 0xc], 0
mov dword [esp], eax
call dword [sym.imp.USER32.dll_AdjustWindowRectEx]
mov edx, dword [ebp - 0x34]
mov edi, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x30]
mov esi, dword [ebp - 0x28]
mov ecx, dword [ebp + 0x1c]
sub edi, edx
sub esp, 0x10
sub esi, eax
test ecx, ecx
js 0xaf729b
mov ecx, dword [ebp - 0x164]
test ecx, ecx
je 0xaf719e
mov edx, dword [sym.imp.USER32.dll_GetSystemMetrics]
mov dword [esp], 0
mov dword [ebp - 0x16c], edx
call edx
mov edx, dword [ebp - 0x16c]
sub eax, edi
sub esp, 4
mov ecx, eax
shr ecx, 0x1f
lea eax, [ecx + eax]
sar eax, 1
mov dword [ebp - 0x24], eax
mov dword [esp], 1
call edx
mov ecx, 0x140
sub eax, esi
sub esp, 4
mov edx, eax
shr edx, 0x1f
lea eax, [edx + eax]
mov edx, dword [ebp - 0x24]
sar eax, 1
mov dword [ebp - 0x20], eax
mov dword [esp + 0xc], eax
mov eax, dword [0x1a528ac]
mov dword [esp + 0x18], ecx
mov dword [esp + 0x14], esi
mov dword [esp + 0x10], edi
mov dword [esp + 8], edx
mov dword [esp + 4], 0xfffffffe
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetWindowPos]
mov eax, dword [0x1a528b0]
mov dword [0x1a528c0], eax
mov eax, dword [0x1a528b4]
sub esp, 0x1c
mov dword [0x1a528c4], eax
mov eax, dword [0x1a528ac]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetForegroundWindow]
sub esp, 4
jmp 0xaf6198
mov eax, dword [ebp - 0x24]
mov edx, dword [ebp - 0x20]
mov dword [ebp - 0x15c], eax
mov dword [0x1a528c0], eax
mov dword [ebp - 0x158], edx
mov dword [0x1a528c4], edx
jmp 0xaf6798
mov edx, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0x14c]
mov eax, dword [edx]
mov edx, eax
or edx, 0x80000000
mov dword [ecx], edx
mov edx, dword [ecx + 4]
mov esi, dword [edx]
test esi, esi
je 0xaf6f2c
or eax, 0xa0000000
mov dword [ecx], eax
mov dword [ebx + 0x20], 0xaf40f0
jmp 0xaf6681
mov dword [esp], 0
call fcn.00ae69b0
jmp 0xaf61bb
mov eax, dword [ebp - 0x14c]
mov dword [eax], 0x10
mov eax, 0x10
jmp 0xaf65c0
cmp dword [ebp - 0x14c], esi
je 0xaf6f81
mov ecx, dword [ebp - 0x14c]
mov dword [ebp - 0x16c], eax
mov dword [esp], ecx
call fcn.00ae2ea0
mov eax, dword [ebp - 0x16c]
mov dword [esp + 4], eax
mov dword [esp], str.DirectDrawClipper::SetHWnd
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov eax, dword [0x1a528ac]
mov dword [esp], eax
call dword [sym.imp.USER32.dll_IsZoomed]
sub esp, 4
test eax, eax
jne 0xaf6681
mov ecx, dword [ebp - 0x14c]
mov eax, dword [ebp - 0x164]
cmp dword [ecx + 8], eax
jne 0xaf6fe1
mov edx, dword [ebp - 0x168]
xor ebx, ebx
cmp dword [ecx + 0xc], edx
mov dword [ebp - 0x150], 0
je 0xaf7049
mov dword [esp], str.SDL_VIDEO_WINDOW_POS
call fcn.00ae6ae0
mov dword [esp], str.SDL_VIDEO_CENTERED
mov ebx, eax
call fcn.00ae6ae0
test ebx, ebx
mov dword [ebp - 0x150], eax
je 0xaf7049
lea eax, [ebp - 0x24]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x20]
mov dword [esp + 8], eax
mov dword [esp + 4], 0x125a0fb
mov dword [esp], ebx
call sub.msvcrt.dll_sscanf
cmp eax, 2
je 0xaf7489
mov ecx, 7
mov edi, str.center
mov esi, ebx
repe cmpsb byte [esi], byte es:[edi]
mov ecx, dword [ebp - 0x150]
cmove ecx, ebx
mov dword [ebp - 0x150], ecx
mov ecx, dword [ebp - 0x14c]
mov eax, dword [0x1a528c4]
mov edx, dword [0x1a528c0]
mov dword [ebp - 0x30], eax
add eax, dword [ecx + 0xc]
mov dword [ebp - 0x34], edx
add edx, dword [ecx + 8]
mov dword [ebp - 0x28], eax
mov eax, dword [0x1a528ac]
mov dword [ebp - 0x2c], edx
mov dword [esp], eax
call dword [sym.imp.USER32.dll_GetMenu]
mov esi, eax
mov eax, dword [0x1a528ac]
sub esp, 4
mov dword [esp + 4], 0xfffffff0
mov dword [esp], eax
call dword [ebp - 0x160]
xor edx, edx
sub esp, 8
test esi, esi
setne dl
mov dword [esp + 4], eax
lea eax, [ebp - 0x34]
mov dword [esp + 8], edx
mov dword [esp + 0xc], 0
mov dword [esp], eax
call dword [sym.imp.USER32.dll_AdjustWindowRectEx]
mov edx, dword [ebp - 0x34]
mov esi, dword [ebp - 0x2c]
mov eax, dword [ebp - 0x30]
mov edi, dword [ebp - 0x28]
mov ecx, dword [ebp - 0x150]
sub esi, edx
sub esp, 0x10
sub edi, eax
test ecx, ecx
je 0xaf7447
mov ebx, dword [sym.imp.USER32.dll_GetSystemMetrics]
mov dword [esp], 0
call ebx
sub eax, esi
sub esp, 4
mov edx, eax
shr edx, 0x1f
lea eax, [edx + eax]
sar eax, 1
mov dword [ebp - 0x20], eax
mov dword [esp], 1
call ebx
sub eax, edi
sub esp, 4
mov edx, eax
shr edx, 0x1f
lea eax, [edx + eax]
mov edx, 0x100
sar eax, 1
mov dword [ebp - 0x24], eax
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x20]
mov dword [esp + 0x18], edx
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], esi
mov dword [esp + 8], eax
mov eax, dword [0x1a528ac]
mov dword [esp + 4], 0xfffffffe
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetWindowPos]
mov eax, dword [0x1a528b0]
mov dword [0x1a528c0], eax
mov eax, dword [0x1a528b4]
sub esp, 0x1c
mov dword [0x1a528c4], eax
jmp 0xaf6681
mov edx, dword [ebp - 0x14c]
mov ecx, dword [ebp - 0x154]
mov eax, dword [edx + 8]
mov dword [ebp - 0x164], ecx
mov edx, dword [edx + 0xc]
jmp 0xaf6da0
mov eax, dword [esi + 4]
movzx eax, byte [eax + 4]
cmp eax, dword [ebp - 0x4c]
jne 0xaf6501
mov dword [ebp - 0x14c], esi
jmp 0xaf658d
mov ecx, dword [0x1a528c0]
test ecx, ecx
jne 0xaf726c
mov ecx, dword [ebp - 0x154]
test ecx, ecx
jne 0xaf726c
mov ecx, dword [0x1a528c4]
test ecx, ecx
jne 0xaf726c
mov dword [ebp - 0x20], 0xffffffff
mov eax, 0xffffffff
mov edx, 0xffffffff
mov dword [ebp - 0x24], 0xffffffff
mov ecx, 0x142
jmp 0xaf6e8b
mov ecx, dword [0x1a528c0]
mov edx, dword [ebp - 0x14c]
mov dword [ebp - 0x15c], ecx
mov ecx, dword [0x1a528c4]
mov eax, dword [edx + 8]
mov edx, dword [edx + 0xc]
mov dword [ebp - 0x158], ecx
jmp 0xaf6da0
mov dword [esp + 4], eax
mov dword [esp], 0x1259f18
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov eax, dword [edx]
add edx, 8
mov ecx, dword [eax]
mov dword [esp + 0xc], 0
mov dword [esp + 8], edx
mov dword [esp + 4], 0
mov dword [esp], eax
call dword [ecx + 0x10]
sub esp, 0x10
test eax, eax
jne 0xaf749e
mov eax, dword [ebx + 0x2ac]
mov eax, dword [eax + 8]
jmp 0xaf662b
mov dword [ebp - 0x24], edx
mov ecx, 0x140
mov dword [ebp - 0x20], eax
jmp 0xaf6e8b
mov dword [esp + 4], eax
mov dword [esp], str.DirectDraw2::SetCooperativeLevel
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov edx, dword [sym.imp.USER32.dll_GetSystemMetrics]
mov dword [esp], 0
mov dword [ebp - 0x16c], edx
call edx
mov edx, dword [ebp - 0x16c]
sub eax, edi
sub esp, 4
mov ecx, eax
shr ecx, 0x1f
lea eax, [ecx + eax]
sar eax, 1
mov dword [ebp - 0x24], eax
mov dword [esp], 1
call edx
sub eax, esi
sub esp, 4
mov edx, eax
shr edx, 0x1f
lea eax, [edx + eax]
sar eax, 1
mov dword [ebp - 0x20], eax
mov dword [esp + 0xc], eax
mov eax, dword [ebp - 0x24]
mov dword [esp + 0x18], 0x140
mov dword [esp + 0x14], esi
mov dword [esp + 0x10], edi
mov dword [esp + 8], eax
mov eax, dword [0x1a528ac]
mov dword [esp + 4], 0xffffffff
mov dword [esp], eax
call dword [sym.imp.USER32.dll_SetWindowPos]
sub esp, 0x1c
jmp 0xaf6ecc
mov dword [ebp - 0x14c], esi
jmp 0xaf60c6
cmp dword [ebp - 0x14c], esi
je 0xaf7349
mov edx, dword [ebp - 0x14c]
mov dword [ebp - 0x16c], eax
mov dword [esp], edx
call fcn.00ae2ea0
mov eax, dword [ebp - 0x16c]
mov dword [esp + 4], eax
mov dword [esp], str.DirectDrawSurface3::SetClipper
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov dword [esp + 4], eax
mov dword [esp], str.DirectDrawSurface::GetSurfaceDesc
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov eax, dword [edx + 4]
movzx eax, byte [eax + 5]
imul ax, word [ebp + 0x10]
add eax, 7
and eax, 0xfffffff8
mov word [edx + 0x10], ax
movzx eax, ax
imul eax, dword [edx + 0xc]
mov dword [esp], eax
call sub.msvcrt.dll_malloc
mov ecx, dword [ebp - 0x14c]
test eax, eax
mov dword [ecx + 0x14], eax
jne 0xaf65af
cmp ecx, esi
je 0xaf73c9
mov dword [esp], ecx
call fcn.00ae2ea0
mov dword [esp], 0
call fcn.00ae69b0
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov dword [esp], str.Primary_DDRAW_surface_is_not_RGB_format
call fcn.00ae6670
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
cmp dword [ebp - 0x14c], esi
je 0xaf67c1
mov ecx, dword [ebp - 0x14c]
mov dword [esp], ecx
call fcn.00ae2ea0
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov dword [esp + 4], eax
mov dword [esp], str.DirectDraw2::CreatePalette
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb
mov ecx, dword [0x1a528c0]
test ecx, ecx
jne 0xaf7479
test ebx, ebx
jne 0xaf7479
cmp dword [0x1a528c4], 0
jne 0xaf7479
mov dword [ebp - 0x24], 0xffffffff
or eax, 0xffffffff
mov edx, 0x102
mov dword [ebp - 0x20], 0xffffffff
jmp 0xaf711d
mov dword [ebp - 0x20], edx
mov edx, 0x100
mov dword [ebp - 0x24], eax
jmp 0xaf711d
mov eax, dword [ebp - 0x20]
mov dword [0x1a528c0], eax
mov eax, dword [ebp - 0x24]
mov dword [0x1a528c4], eax
jmp 0xaf702c
cmp dword [ebp - 0x14c], esi
je 0xaf74c0
mov edx, dword [ebp - 0x14c]
mov dword [ebp - 0x16c], eax
mov dword [esp], edx
call fcn.00ae2ea0
mov eax, dword [ebp - 0x16c]
mov dword [esp + 4], eax
mov dword [esp], str.DirectDraw2::CreateClipper
call fcn.00af4e30
mov dword [ebp - 0x14c], 0
jmp 0xaf61bb