Function at 0x404760
Capabilities:
Hide graphical window

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
mov eax, dword [0x428024]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
xor edi, edi
push edi
push edi
mov dword [ebp - 0x58], eax
mov dword [0x42a28c], eax
push 0xca0000
lea eax, [ebp - 0x4c]
push eax
mov dword [ebp - 0x4c], edi
mov dword [ebp - 0x48], edi
mov dword [ebp - 0x44], 0x282
mov dword [ebp - 0x40], 0x192
call dword [sym.imp.USER32.dll_AdjustWindowRectEx]
mov ebx, dword [ebp - 0x44]
mov esi, dword [ebp - 0x40]
sub ebx, dword [ebp - 0x4c]
sub esi, dword [ebp - 0x48]
push edi
mov dword [ebp - 0x50], edi
call dword [sym.imp.USER32.dll_GetDC]
mov edi, eax
xor eax, eax
cmp edi, eax
je 0x4047e7
push 0xc
push edi
call dword [sym.imp.GDI32.dll_GetDeviceCaps]
push edi
push 0
mov dword [ebp - 0x54], eax
call dword [sym.imp.USER32.dll_ReleaseDC]
xor eax, eax
cmp dword [ebp - 0x54], 0x10
jl 0x4047e7
mov dword [ebp - 0x50], 1
mov dword [ebp - 0x2c], 0x280
mov dword [ebp - 0x28], esi
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], eax
mov dword [ebp - 0xc], eax
mov dword [ebp - 8], eax
cmp dword [ebp - 0x50], eax
je 0x404883
push eax
lea ecx, [ebp - 0x3c]
push ecx
push eax
push 0x30
mov dword [ebp - 0x3c], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], eax
mov dword [ebp - 0x30], eax
call dword [sym.imp.USER32.dll_SystemParametersInfoW]
test eax, eax
je 0x404857
mov edx, dword [ebp - 0x34]
mov eax, edx
sub eax, dword [ebp - 0x3c]
cmp eax, dword [ebp - 0x2c]
jl 0x404857
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x38]
mov edi, eax
sub edi, ecx
cmp edi, dword [ebp - 0x28]
jl 0x404857
mov edi, dword [ebp - 0x3c]
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x10], ecx
mov dword [ebp - 0xc], edx
mov dword [ebp - 8], eax
mov edi, dword [sym.imp.USER32.dll_GetSystemMetrics]
push 1
call edi
push 0
mov dword [ebp - 0x54], eax
call edi
cmp eax, dword [ebp - 0x2c]
jl 0x404883
mov edx, dword [ebp - 0x54]
cmp edx, dword [ebp - 0x28]
jl 0x404883
xor ecx, ecx
mov dword [ebp - 0x24], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], edx
mov edi, dword [sym.imp.USER32.dll_IsRectEmpty]
lea ecx, [ebp - 0x14]
push ecx
call edi
test eax, eax
je 0x4048a6
lea edx, [ebp - 0x2c]
push edx
push 0x404630
push 0
push 0
call dword [sym.imp.USER32.dll_EnumDisplayMonitors]
lea eax, [ebp - 0x14]
push eax
call edi
test eax, eax
jne 0x4048be
mov ecx, dword [ebp - 0x14]
mov edi, dword [ebp - 0x10]
mov edx, dword [ebp - 0xc]
mov eax, dword [ebp - 8]
jmp 0x4048d8
lea eax, [ebp - 0x24]
push eax
call edi
test eax, eax
jne 0x40497e
mov ecx, dword [ebp - 0x24]
mov edi, dword [ebp - 0x20]
mov edx, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x18]
sub eax, edi
push 0
sub eax, esi
mov dword [ebp - 0x34], edx
mov edx, dword [ebp - 0x58]
push edx
cdq
push 0
sub eax, edx
push 0
sar eax, 1
push esi
add eax, edi
push ebx
push eax
mov eax, dword [ebp - 0x34]
sub eax, ecx
sub eax, ebx
cdq
sub eax, edx
sar eax, 1
add eax, ecx
push eax
push 0xca0000
push 0x42a1c0
push str.KT_NOBUNAGA_NO_YABOU_GAMEWINDOW
push 0
call dword [sym.imp.USER32.dll_CreateWindowExW]
mov esi, eax
test esi, esi
jne 0x404933
or eax, 0xffffffff
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004186ce
mov esp, ebp
pop ebp
ret
push 0
push esi
mov dword [0x42a288], esi
call dword [sym.imp.IMM32.dll_ImmAssociateContext]
mov eax, dword [ebp + 0xc]
push eax
push esi
call dword [sym.imp.USER32.dll_ShowWindow]
push esi
call dword [sym.imp.USER32.dll_UpdateWindow]
call fcn.00404e10
mov ebx, eax
call fcn.00404f90
mov esi, eax
test esi, esi
js 0x40496b
call fcn.00404f20
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004186ce
mov esp, ebp
pop ebp
ret
mov ecx, dword [ebp - 4]
xor eax, eax
cmp dword [ebp - 0x50], eax
pop edi
setne al
pop esi
xor ecx, ebp
pop ebx
add eax, 0xfffffffc
call fcn.004186ce
mov esp, ebp
pop ebp
ret