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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x60c1ac
mov eax, dword fs:[0]
push eax
sub esp, 0x4a0
mov eax, dword [0x6687b8]
xor eax, esp
mov dword [esp + 0x498], eax
push ebx
push esi
push edi
mov eax, dword [0x6687b8]
xor eax, esp
push eax
lea eax, [esp + 0x4b0]
mov dword fs:[0], eax
mov eax, dword [ebp + 0xc]
mov esi, dword [ebp + 8]
mov edi, ecx
mov dword [esp + 0x24], edi
mov dword [esp + 0x1c], eax
call fcn.0046c900
mov ecx, dword [esi + 8]
mov eax, dword [esi + 0x24]
push ecx
call fcn.00508370
push eax
push 0x637c88
call fcn.0040b2a0
add esp, 0xc
cmp dword [esi + 0x2c], 1
jne 0x50983d
cmp dword [esi + 0x30], 2
je 0x50983d
push 0x637cac
call fcn.0040b2a0
add esp, 4
jmp 0x50ab59
lea edx, [esp + 0x6c]
push edx
call fcn.00470f50
xor ebx, ebx
mov dword [esp + 0x4b8], ebx
mov eax, dword [esp + 0x1c]
push eax
lea ecx, [edi + 0xdc0]
push ecx
mov ecx, dword [ebp + 0x10]
lea edx, [esp + 0x74]
call fcn.00471730
test al, al
je 0x50ab11
mov eax, dword [esi + 0x24]
sub eax, 0x10901
je 0x50a2c5
mov ecx, 2
sub eax, ecx
je 0x509d5f
sub eax, ecx
jne 0x50ab45
cmp dword [esi + 0x2c], ebx
jne 0x509bfa
mov dword [esp + 0x18], ebx
mov dword [esp + 0x1c], ebx
mov byte [esp + 0x17], bl
mov dword [esp + 0x420], 0xf
mov dword [esp + 0x41c], ebx
mov byte [esp + 0x40c], bl
mov bl, 0x21
push str.RedirectIP
lea ecx, [esp + 0x3f0]
mov byte [esp + 0x4bc], bl
call fcn.00401ca0
lea edx, [esp + 0x24]
push edx
lea eax, [esp + 0x3f0]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x22
call fcn.00472f00
lea ecx, [esp + 0x3ec]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.RedirectPort
lea ecx, [esp + 0x364]
call fcn.00401ca0
lea ecx, [esp + 0x28]
push ecx
lea edx, [esp + 0x364]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x23
call fcn.0050b0c0
lea ecx, [esp + 0x360]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.CurPoint
lea ecx, [esp + 0x134]
call fcn.00401ca0
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x134]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x24
call fcn.00472f00
lea ecx, [esp + 0x130]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.CurLevel
lea ecx, [esp + 0x2bc]
call fcn.00401ca0
lea edx, [esp + 0x1c]
push edx
lea eax, [esp + 0x2bc]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x25
call fcn.0050b0c0
lea ecx, [esp + 0x2b8]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.IconState
lea ecx, [esp + 0x16c]
call fcn.00401ca0
lea ecx, [esp + 0x17]
push ecx
lea edx, [esp + 0x16c]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x26
call fcn.0050b300
lea ecx, [esp + 0x168]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push 0x629e74
lea ecx, [esp + 0x1a4]
call fcn.00401ca0
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x1a4]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x27
call fcn.00472f00
lea ecx, [esp + 0x1a0]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.LevelName
lea ecx, [esp + 0xfc]
call fcn.00401ca0
lea edx, [esp + 0x408]
push edx
lea eax, [esp + 0xfc]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x28
call fcn.004734e0
lea ecx, [esp + 0xf8]
call fcn.00401ce0
lea ecx, [esp + 0x20]
call fcn.00403890
push edi
lea ebx, [esp + 0x24]
mov byte [esp + 0x4bc], 0x29
call fcn.00509010
push 0x7c
lea ecx, [esp + 0x428]
push 0
push ecx
call fcn.005da970
mov eax, dword [esp + 0x2c]
add esp, 0xc
push 0x7c
lea edx, [esp + 0x428]
push edx
push 0
push eax
call fcn.005071d0
movzx esi, word [esp + 0x2c]
movzx ebx, byte [esp + 0x27]
mov ecx, dword [esp + 0x28]
mov eax, dword [esp + 0x41c]
add esp, 0x10
cmp dword [esp + 0x420], 0x10
mov dword [esp + 0x424], esi
mov dword [esp + 0x428], ecx
mov dword [esp + 0x42c], ebx
jae 0x509b17
lea eax, [esp + 0x40c]
push 0x36
lea edx, [esp + 0x434]
push edx
push 0xffffffffffffffff
push eax
push 0
push 0x3a8
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
cmp dword [esp + 0x420], 0x10
mov ecx, dword [esp + 0x40c]
jae 0x509b49
lea ecx, [esp + 0x40c]
lea eax, [esp + 0x98]
push eax
call fcn.00426330
push ebx
mov byte [esp + 0x4bc], 0x2a
mov ecx, dword [eax]
mov edx, dword [esp + 0x1c]
push esi
push ecx
push edx
push 0x637fd8
call fcn.0040b2a0
add esp, 0x14
lea ecx, [esp + 0x98]
mov byte [esp + 0x4b8], 0x29
call fcn.00403870
mov ecx, dword [esp + 0x20]
lea eax, [esp + 0x424]
push eax
push 0
push ecx
mov ecx, 0x7c
call fcn.005073e0
add esp, 0xc
cmp dword [edi + 0x1224], 0
mov dword [edi + 0x1218], 1
jbe 0x509bd7
lea eax, [edi + 0x121c]
call fcn.0050ad80
mov edx, dword [edi + 0x10c]
push 0
push 0
push eax
push edx
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x509be0
push 1
mov esi, edi
call fcn.0050abf0
lea ecx, [esp + 0x20]
call fcn.00403870
lea ecx, [esp + 0x408]
call fcn.00401ce0
jmp 0x50ab45
cmp dword [esi + 0x30], ecx
jne 0x50ab45
push str.RedirectIP
lea ecx, [esp + 0x1c0]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], ebx
call fcn.00401ca0
lea eax, [esp + 0x1c]
push eax
lea ecx, [esp + 0x1c0]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x2b
call fcn.00472f00
lea ecx, [esp + 0x1bc]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.RedirectPort
lea ecx, [esp + 0x1dc]
call fcn.00401ca0
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x1dc]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x2c
call fcn.0050b0c0
lea ecx, [esp + 0x1d8]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
mov word [edi + 0x120c], ax
movzx eax, ax
push eax
push esi
push 0x638050
mov dword [edi + 0x1208], esi
mov dword [esp + 0x30], eax
call fcn.0040b2a0
add esp, 0xc
lea ecx, [esp + 0x20]
call fcn.00403890
push edi
lea ebx, [esp + 0x24]
mov byte [esp + 0x4bc], 0x2d
call fcn.00509010
mov ebx, dword [esp + 0x20]
xor eax, eax
push 0x2c
lea ecx, [esp + 0x34]
push ecx
push 0xc00
push ebx
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], eax
call fcn.005071d0
mov dx, word [esp + 0x28]
lea eax, [esp + 0x40]
push eax
push 0xc00
push ebx
mov ecx, 0x2c
mov dword [esp + 0x68], esi
mov word [esp + 0x6c], dx
call fcn.005073e0
mov ecx, dword [edi + 0x10c]
add esp, 0x1c
push 0
push 0
push 0x8291
push ecx
call dword [sym.imp.USER32.dll_PostMessageW]
mov edx, dword [esp + 0x24]
push edx
jmp 0x50a2a9
cmp dword [esi + 0x2c], ebx
jne 0x50a149
mov dword [esp + 0x20], ebx
mov dword [esp + 0x18], ebx
mov byte [esp + 0x17], bl
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x420], 0xf
mov dword [esp + 0x41c], ebx
mov byte [esp + 0x40c], bl
mov bl, 0x14
push str.RedirectIP
lea ecx, [esp + 0x2f4]
mov byte [esp + 0x4bc], bl
call fcn.00401ca0
lea eax, [esp + 0x24]
push eax
lea ecx, [esp + 0x2f4]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x15
call fcn.00472f00
lea ecx, [esp + 0x2f0]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.RedirectPort
lea ecx, [esp + 0x214]
call fcn.00401ca0
lea edx, [esp + 0x28]
push edx
lea eax, [esp + 0x214]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x16
call fcn.0050b0c0
lea ecx, [esp + 0x210]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.CurPoint
lea ecx, [esp + 0x3d4]
call fcn.00401ca0
lea ecx, [esp + 0x20]
push ecx
lea edx, [esp + 0x3d4]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x17
call fcn.00472f00
lea ecx, [esp + 0x3d0]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.CurLevel
lea ecx, [esp + 0x24c]
call fcn.00401ca0
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x24c]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x18
call fcn.0050b0c0
lea ecx, [esp + 0x248]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.IconState
lea ecx, [esp + 0x32c]
call fcn.00401ca0
lea edx, [esp + 0x17]
push edx
lea eax, [esp + 0x32c]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x19
call fcn.0050b300
lea ecx, [esp + 0x328]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push 0x637cdc
lea ecx, [esp + 0x284]
call fcn.00401ca0
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x284]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x1a
call fcn.0050b0c0
lea ecx, [esp + 0x280]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.LevelName
lea ecx, [esp + 0x39c]
call fcn.00401ca0
lea eax, [esp + 0x408]
push eax
lea ecx, [esp + 0x39c]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x1b
call fcn.004734e0
lea ecx, [esp + 0x398]
call fcn.00401ce0
lea ecx, [esp + 0x28]
call fcn.00403890
push edi
lea ebx, [esp + 0x2c]
mov byte [esp + 0x4bc], 0x1c
call fcn.00509010
push 0x7c
lea edx, [esp + 0x428]
push 0
push edx
call fcn.005da970
mov esi, dword [esp + 0x34]
add esp, 0xc
push 0x7c
lea eax, [esp + 0x428]
push eax
push 0
push esi
call fcn.005071d0
movzx eax, word [esp + 0x28]
mov ecx, dword [esp + 0x30]
mov dword [esp + 0x434], eax
movzx eax, byte [esp + 0x27]
mov ebx, 0x10
add esp, 0x10
cmp dword [esp + 0x420], ebx
mov dword [esp + 0x42c], eax
mov eax, dword [esp + 0x40c]
mov dword [esp + 0x428], ecx
jae 0x509feb
lea eax, [esp + 0x40c]
push 0x36
lea edx, [esp + 0x434]
push edx
push 0xffffffffffffffff
push eax
push 0
push 0x3a8
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
cmp dword [esp + 0x420], ebx
mov ecx, dword [esp + 0x40c]
jae 0x50a01c
lea ecx, [esp + 0x40c]
lea eax, [esp + 0x9c]
push eax
call fcn.00426330
mov byte [esp + 0x4b8], 0x1d
movzx ebx, word [esp + 0x1c]
movzx ecx, byte [esp + 0x17]
mov edx, dword [esp + 0x20]
push ebx
push ecx
movzx ecx, word [esp + 0x20]
push ecx
mov ecx, dword [eax]
push ecx
push edx
push 0x637eb8
call fcn.0040b2a0
add esp, 0x18
lea ecx, [esp + 0x9c]
mov byte [esp + 0x4b8], 0x1c
call fcn.00403870
lea eax, [esp + 0x424]
push eax
push 0
push esi
mov ecx, 0x7c
call fcn.005073e0
xor eax, eax
add esp, 0xc
push 0x2c
lea ecx, [esp + 0x34]
push ecx
push 0xc00
push esi
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], eax
call fcn.005071d0
lea edx, [esp + 0x40]
push edx
push 0xc00
push esi
mov ecx, 0x2c
mov dword [esp + 0x4c], ebx
call fcn.005073e0
add esp, 0x1c
push 0x637f58
call fcn.0040b2a0
add esp, 4
mov eax, esi
call fcn.00507580
cmp dword [edi + 0x1224], 0
mov dword [edi + 0x1214], 1
jbe 0x50a126
lea eax, [edi + 0x121c]
call fcn.0050ad80
push 0
push 0
push eax
mov eax, dword [edi + 0x10c]
push eax
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x50a12f
push 1
mov esi, edi
call fcn.0050abf0
lea ecx, [esp + 0x28]
call fcn.00403870
lea ecx, [esp + 0x408]
call fcn.00401ce0
jmp 0x50ab45
cmp dword [esi + 0x30], ecx
jne 0x50ab45
push str.RedirectIP
lea ecx, [esp + 0x118]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], ebx
call fcn.00401ca0
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x118]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x1e
call fcn.00472f00
lea ecx, [esp + 0x114]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.RedirectPort
lea ecx, [esp + 0x150]
call fcn.00401ca0
lea eax, [esp + 0x18]
push eax
lea ecx, [esp + 0x150]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x1f
call fcn.0050b0c0
lea ecx, [esp + 0x14c]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
mov word [edi + 0x1204], ax
movzx eax, ax
push eax
push esi
push 0x637f78
mov dword [edi + 0x1200], esi
mov dword [esp + 0x30], eax
call fcn.0040b2a0
add esp, 0xc
lea ecx, [esp + 0x20]
call fcn.00403890
push edi
lea ebx, [esp + 0x24]
mov byte [esp + 0x4bc], 0x20
call fcn.00509010
mov ebx, dword [esp + 0x20]
xor eax, eax
push 0x2c
lea edx, [esp + 0x34]
push edx
push 0xc00
push ebx
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
mov dword [esp + 0x5c], eax
mov dword [esp + 0x60], eax
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], eax
call fcn.005071d0
mov ax, word [esp + 0x28]
lea ecx, [esp + 0x40]
push ecx
push 0xc00
push ebx
mov ecx, 0x2c
mov dword [esp + 0x68], esi
mov word [esp + 0x6c], ax
call fcn.005073e0
mov edx, dword [edi + 0x10c]
add esp, 0x1c
push 0
push 0
push 0x8290
push edx
call dword [sym.imp.USER32.dll_PostMessageW]
mov eax, dword [esp + 0x24]
push eax
push esi
push 0x637e70
call fcn.0040b2a0
add esp, 0xc
lea ecx, [esp + 0x20]
call fcn.00403870
jmp 0x50ab45
cmp dword [esi + 0x2c], ebx
jne 0x50a997
push str.RedirectIP
lea ecx, [esp + 0x188]
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], ebx
mov dword [esp + 0x60], ebx
mov dword [esp + 0x64], ebx
mov dword [esp + 0x30], ebx
call fcn.00401ca0
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x188]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 1
call fcn.00472f00
lea ecx, [esp + 0x184]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.RedirectPort
lea ecx, [esp + 0x1f8]
call fcn.00401ca0
lea eax, [esp + 0x28]
push eax
lea ecx, [esp + 0x1f8]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 2
call fcn.0050b0c0
lea ecx, [esp + 0x1f4]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push 0x637cdc
lea ecx, [esp + 0x230]
call fcn.00401ca0
lea edx, [esp + 0x64]
push edx
lea eax, [esp + 0x230]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 3
call fcn.0050b0c0
lea ecx, [esp + 0x22c]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.KeyTimeOut
lea ecx, [esp + 0x268]
call fcn.00401ca0
lea ecx, [esp + 0x68]
push ecx
lea edx, [esp + 0x268]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 4
call fcn.0050b0c0
lea ecx, [esp + 0x264]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.ParaA
lea ecx, [esp + 0x2a0]
call fcn.00401ca0
lea eax, [esp + 0x5c]
push eax
lea ecx, [esp + 0x2a0]
push ecx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 5
call fcn.00472f00
lea ecx, [esp + 0x29c]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.ParaB
lea ecx, [esp + 0x2d8]
call fcn.00401ca0
mov byte [esp + 0x4b8], 6
lea edx, [esp + 0x60]
push edx
lea eax, [esp + 0x2d8]
push eax
lea ecx, [esp + 0x74]
call fcn.00472f00
lea ecx, [esp + 0x2d4]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.ParaC
lea ecx, [esp + 0x310]
call fcn.00401ca0
lea ecx, [esp + 0x2c]
push ecx
lea edx, [esp + 0x310]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 7
call fcn.00472f00
lea ecx, [esp + 0x30c]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
lea eax, [esp + 0x424]
push eax
call fcn.0046ce10
push str.LevelPoint
lea ecx, [esp + 0x348]
mov byte [esp + 0x4bc], 8
call fcn.00401ca0
lea ecx, [esp + 0x424]
push ecx
lea edx, [esp + 0x348]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 9
call fcn.00473010
lea ecx, [esp + 0x344]
mov byte [esp + 0x4b8], 8
call fcn.00401ce0
mov eax, dword [esp + 0x43c]
mov ecx, eax
shl ecx, 4
sub ecx, eax
lea eax, [ecx*8 + 4]
push eax
mov dword [esp + 0x1c], eax
call fcn.005d1ef5
mov edx, dword [esp + 0x1c]
add esp, 4
push edx
mov esi, eax
push ebx
push esi
mov dword [esp + 0x28], esi
call fcn.005da970
add esp, 0xc
mov dword [esp + 0xf4], esi
mov byte [esp + 0x4b8], 0xa
mov eax, dword [0x677600]
mov edx, dword [eax + 0xc]
mov ecx, 0x677600
call edx
add eax, 0x10
mov dword [esp + 0x28], eax
mov dword [esp + 0x420], 0xf
mov dword [esp + 0x41c], ebx
mov byte [esp + 0x40c], bl
mov byte [esp + 0x4b8], 0xc
mov eax, dword [esp + 0x43c]
xor ecx, ecx
mov dword [esi], eax
cmp dword [esp + 0x43c], ebx
mov dword [esp + 0x18], ecx
jbe 0x50a7bc
lea edx, [esi + 0xc]
mov dword [esp + 0x20], edx
jmp 0x50a5b4
mov ecx, dword [esp + 0x18]
mov edx, dword [esp + 0x448]
cmp edx, ebx
je 0x50a7bc
mov eax, dword [esp + 0x44c]
sub eax, edx
sar eax, 2
cmp ecx, eax
jae 0x50a7bc
mov eax, dword [edx + ecx*4]
cmp eax, ebx
mov dword [esp + 0x18], eax
je 0x50a7bc
lea esi, [ecx + 1]
push esi
push str.Level_u
lea edi, [esp + 0x30]
call fcn.004ce3a0
mov eax, dword [esp + 0x30]
add esp, 8
push eax
lea ecx, [esp + 0xdc]
call fcn.00401ca0
mov byte [esp + 0x4b8], 0xd
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
add ecx, 0xfffffff8
push ecx
lea ecx, [esp + 0xdc]
call fcn.0050b1d0
mov byte [esp + 0x4b8], 0xc
cmp dword [esp + 0xf0], 0x10
jb 0x50a64e
mov edx, dword [esp + 0xdc]
push edx
call fcn.005d2367
add esp, 4
push esi
push str.LevelName_u
lea edi, [esp + 0x30]
mov dword [esp + 0xf8], 0xf
mov dword [esp + 0xf4], ebx
mov byte [esp + 0xe4], bl
call fcn.004ce3a0
mov eax, dword [esp + 0x30]
add esp, 8
push eax
lea ecx, [esp + 0xc0]
call fcn.00401ca0
lea ecx, [esp + 0x408]
mov byte [esp + 0x4b8], 0xe
mov edx, dword [esp + 0x18]
push ecx
lea ecx, [esp + 0xc0]
call fcn.00473120
mov edi, 0x10
mov byte [esp + 0x4b8], 0xc
cmp dword [esp + 0xd4], edi
mov byte [esp + 0x17], al
jb 0x50a6d4
mov edx, dword [esp + 0xc0]
push edx
call fcn.005d2367
add esp, 4
cmp byte [esp + 0x17], bl
mov dword [esp + 0xd4], 0xf
mov dword [esp + 0xd0], ebx
mov byte [esp + 0xc0], bl
je 0x50a720
cmp dword [esp + 0x420], edi
mov eax, dword [esp + 0x40c]
jae 0x50a70a
lea eax, [esp + 0x40c]
mov ecx, dword [esp + 0x20]
push 0x36
push ecx
push 0xffffffffffffffff
push eax
push ebx
push 0x3a8
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push esi
push str.LevelAdd_u
lea edi, [esp + 0x30]
call fcn.004ce3a0
mov edx, dword [esp + 0x30]
add esp, 8
push edx
lea ecx, [esp + 0xa4]
call fcn.00401ca0
mov byte [esp + 0x4b8], 0xf
mov eax, dword [esp + 0x20]
mov edx, dword [esp + 0x18]
add eax, 0xfffffffc
push eax
lea ecx, [esp + 0xa4]
call fcn.0050b1d0
mov byte [esp + 0x4b8], 0xc
cmp dword [esp + 0xb8], 0x10
jb 0x50a785
mov ecx, dword [esp + 0xa4]
push ecx
call fcn.005d2367
add esp, 4
add dword [esp + 0x20], 0x78
cmp esi, dword [esp + 0x43c]
mov edi, dword [esp + 0x24]
mov dword [esp + 0x18], esi
mov esi, dword [esp + 0x1c]
mov dword [esp + 0xb8], 0xf
mov dword [esp + 0xb4], ebx
mov byte [esp + 0xa4], bl
jb 0x50a5b0
mov edx, dword [esp + 0x2c]
movzx eax, word [esp + 0x68]
movzx ecx, word [esp + 0x64]
push edx
mov edx, dword [esp + 0x64]
push edx
mov edx, dword [esp + 0x64]
push edx
push eax
push ecx
push 0x637d40
call fcn.0040b2a0
mov eax, dword [0x677600]
mov edx, dword [eax + 0xc]
add esp, 0x18
mov ecx, 0x677600
call edx
add eax, 0x10
mov dword [esp + 0x24], eax
push edi
lea ebx, [esp + 0x28]
mov byte [esp + 0x4bc], 0x10
call fcn.00509010
mov ebx, dword [esp + 0x24]
xor eax, eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
push 0x2c
lea eax, [esp + 0x34]
push eax
push 0xc00
push ebx
call fcn.005071d0
movzx eax, word [esp + 0x74]
mov ecx, dword [esp + 0x6c]
mov edx, dword [esp + 0x70]
mov dword [esp + 0x40], eax
movzx eax, word [esp + 0x78]
mov dword [esp + 0x48], ecx
lea ecx, [esp + 0x40]
push ecx
mov dword [esp + 0x48], eax
mov eax, dword [esp + 0x40]
push 0xc00
push ebx
mov ecx, 0x2c
mov dword [esp + 0x58], edx
mov dword [esp + 0x5c], eax
call fcn.005073e0
mov eax, dword [esi]
add esp, 0x1c
mov edx, eax
shl edx, 4
push esi
sub edx, eax
push 0x1000
lea ecx, [edx*8 + 4]
push ebx
call fcn.005073e0
add esp, 0xc
cmp dword [edi + 0x1224], 0
mov dword [edi + 0x1210], 1
jbe 0x50a8e3
lea eax, [edi + 0x121c]
call fcn.0050ad80
push 0
push 0
push eax
mov eax, dword [edi + 0x10c]
push eax
call dword [sym.imp.USER32.dll_PostMessageW]
jmp 0x50a8f0
push 1
mov esi, edi
call fcn.0050abf0
mov esi, dword [esp + 0x1c]
lea eax, [ebx - 0x10]
mov byte [esp + 0x4b8], 0xc
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x50a914
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp dword [esp + 0x420], 0x10
jb 0x50a92e
mov ecx, dword [esp + 0x40c]
push ecx
call fcn.005d2367
add esp, 4
mov byte [esp + 0x4b8], 0xa
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
mov dword [esp + 0x420], 0xf
mov dword [esp + 0x41c], 0
mov byte [esp + 0x40c], 0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x50a974
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
push esi
call fcn.005d28c2
add esp, 4
lea ecx, [esp + 0x424]
push ecx
mov byte [esp + 0x4bc], 0
call fcn.0046cec0
jmp 0x50ab45
cmp dword [esi + 0x30], 2
jne 0x50ab45
push str.RedirectIP
lea ecx, [esp + 0x380]
mov dword [esp + 0x28], ebx
mov dword [esp + 0x20], ebx
call fcn.00401ca0
lea edx, [esp + 0x24]
push edx
lea eax, [esp + 0x380]
push eax
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x11
call fcn.00472f00
lea ecx, [esp + 0x37c]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
push str.RedirectPort
lea ecx, [esp + 0x3b8]
call fcn.00401ca0
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x3b8]
push edx
lea ecx, [esp + 0x74]
mov byte [esp + 0x4c0], 0x12
call fcn.0050b0c0
lea ecx, [esp + 0x3b4]
mov byte [esp + 0x4b8], bl
call fcn.00401ce0
mov eax, dword [esp + 0x1c]
mov esi, dword [esp + 0x24]
mov word [edi + 0x11fc], ax
movzx eax, ax
push eax
push esi
push 0x637e18
mov dword [edi + 0x11f8], esi
mov dword [esp + 0x30], eax
call fcn.0040b2a0
add esp, 0xc
lea ecx, [esp + 0x2c]
call fcn.00403890
push edi
lea ebx, [esp + 0x30]
mov byte [esp + 0x4bc], 0x13
call fcn.00509010
mov ebx, dword [esp + 0x2c]
xor eax, eax
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
mov dword [esp + 0x44], eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], eax
mov dword [esp + 0x54], eax
mov dword [esp + 0x58], eax
push 0x2c
lea eax, [esp + 0x34]
push eax
push 0xc00
push ebx
call fcn.005071d0
mov cx, word [esp + 0x2c]
lea edx, [esp + 0x40]
push edx
mov word [esp + 0x5c], cx
push 0xc00
push ebx
mov ecx, 0x2c
mov dword [esp + 0x60], esi
call fcn.005073e0
mov eax, dword [edi + 0x10c]
add esp, 0x1c
push 0
push 0
push 0x828f
push eax
call dword [sym.imp.USER32.dll_PostMessageW]
mov ecx, dword [esp + 0x24]
push ecx
push esi
push 0x637e70
call fcn.0040b2a0
add esp, 0xc
lea ecx, [esp + 0x2c]
call fcn.00403870
jmp 0x50ab45
push str.penc
call fcn.0040b2a0
mov edx, dword [edi + 0x10c]
add esp, 4
push edx
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
je 0x50ab3e
mov eax, dword [edi + 0x10c]
push eax
call dword [sym.imp.USER32.dll_DestroyWindow]
jmp 0x50ab45
push ebx
call dword [sym.imp.USER32.dll_PostQuitMessage]
lea ecx, [esp + 0x6c]
mov dword [esp + 0x4b8], 0xffffffff
call fcn.00470fe0
mov ecx, dword [esp + 0x4b0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x498]
xor ecx, esp
call fcn.005d28b3
mov esp, ebp
pop ebp
ret 0xc