Function at 0x401000
Capabilities:
Check mutex on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x600c
call fcn.004d0180
mov eax, dword [0x76c500]
xor eax, ebp
mov dword [ebp - 4], eax
mov dword [0x84b4b8], 0xffffffff
mov dword [0x84cf8c], 0
call fcn.004cffbb
add eax, 0x40
mov dword [0x84b668], eax
push str.ARK_X_TRAiN_GUI
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateMutexA]
mov dword [ebp - 0xfc4], eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0xb7
jne 0x4010df
push 0x4f6038
push 0
call dword [sym.imp.USER32.dll_FindWindowA]
mov dword [ebp - 0xfbc], eax
push 4
mov eax, dword [ebp - 0xfbc]
push eax
call dword [sym.imp.USER32.dll_GetWindow]
mov dword [ebp - 0x6004], eax
mov ecx, dword [ebp - 0x6004]
push ecx
call dword [sym.imp.USER32.dll_IsIconic]
test eax, eax
je 0x4010b2
push 0
push 0xf120
push 0x112
mov edx, dword [ebp - 0xfbc]
push edx
call dword [sym.imp.USER32.dll_PostMessageA]
jmp 0x4010cb
push 0x43
push 0
push 0
push 0
push 0
push 0xffffffffffffffff
mov eax, dword [ebp - 0xfbc]
push eax
call dword [sym.imp.USER32.dll_SetWindowPos]
mov ecx, dword [ebp - 0xfc4]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
jmp 0x40137f
push 0x100
lea edx, [ebp - 0x6000]
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea eax, [ebp - 0x5ef8]
push eax
lea ecx, [ebp - 0x6000]
push ecx
mov edx, dword [0x84b4b4]
push edx
call fcn.0040e6f0
add esp, 0xc
mov dword [ebp - 0xfb4], 0
mov eax, dword [ebp - 0xfb4]
mov dword [ebp + eax*4 - 0x5de8], 0x4f6044
mov ecx, dword [ebp - 0xfb4]
add ecx, 1
mov dword [ebp - 0xfb4], ecx
mov dword [ebp - 0x5dec], 0
lea edx, [ebp - 0xfb0]
push edx
lea eax, [ebp - 0x5dec]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
mov edx, dword [0x84b4b4]
push edx
call fcn.00410e50
add esp, 0x10
test eax, eax
jne 0x40125c
cmp dword [ebp - 0xfb4], 0x1388
jl 0x4011ad
mov dword [0x84cf94], 2
push 0x76d784
push 0x84b460
call fcn.00475950
add esp, 8
mov eax, dword [0x84b668]
push eax
push 0x84b460
call fcn.00475cf0
add esp, 8
call fcn.00402370
lea ecx, [ebp - 0xfb0]
push ecx
call fcn.004cff30
add esp, 4
cmp eax, 0xfa0
ja 0x401257
push 0x101
call fcn.004cfe98
add esp, 4
mov dword [ebp - 0x600c], eax
mov edx, dword [ebp - 0xfb4]
mov eax, dword [ebp - 0x600c]
mov dword [ebp + edx*4 - 0x5de8], eax
cmp dword [ebp - 0x600c], 0
jne 0x40122b
mov dword [0x84cf94], 2
push 0x76d785
push 0x84b460
call fcn.00475950
add esp, 8
mov ecx, dword [0x84b668]
push ecx
push 0x84b460
call fcn.00475cf0
add esp, 8
call fcn.00402370
lea edx, [ebp - 0xfb0]
push edx
mov eax, dword [ebp - 0xfb4]
mov ecx, dword [ebp + eax*4 - 0x5de8]
push ecx
call fcn.004cfda0
add esp, 8
mov edx, dword [ebp - 0xfb4]
add edx, 1
mov dword [ebp - 0xfb4], edx
jmp 0x401144
mov eax, dword [ebp + 8]
mov dword [0x84b45c], eax
mov ecx, dword [ebp + 0x14]
mov dword [0x84b458], ecx
mov dword [0x84b4b8], 0
mov dword [0x84cf8c], 0
call fcn.004cffbb
add eax, 0x40
mov dword [0x84b668], eax
mov dword [0x84b4b4], 1
mov dword [0x84b4c0], 0
push 0x4f6050
push 0x84b460
call fcn.004cfda0
add esp, 8
push 0x84b460
call fcn.00402390
add esp, 4
test eax, eax
je 0x4012ca
call fcn.00402370
push 0
push 0
push 0
push 0x84cf98
call dword [sym.imp.USER32.dll_GetMessageA]
mov dword [ebp - 0x6008], eax
cmp dword [ebp - 0x6008], 0
je 0x40131e
push 0x84cf98
mov edx, dword [0x84b450]
push edx
mov eax, dword [0x831d0c]
push eax
call dword [sym.imp.USER32.dll_TranslateAcceleratorA]
test eax, eax
jne 0x40131c
push 0x84cf98
call dword [sym.imp.USER32.dll_TranslateMessage]
push 0x84cf98
call dword [sym.imp.USER32.dll_DispatchMessageA]
jmp 0x4012ca
call fcn.00402370
lea ecx, [ebp - 0x5de8]
push ecx
mov edx, dword [ebp - 0xfb4]
push edx
call fcn.00401390
add esp, 8
mov dword [ebp - 0xfc0], 0
jmp 0x401354
mov eax, dword [ebp - 0xfc0]
add eax, 1
mov dword [ebp - 0xfc0], eax
mov ecx, dword [ebp - 0xfc0]
cmp ecx, dword [ebp - 0xfb4]
jge 0x40137a
mov edx, dword [ebp - 0xfc0]
mov eax, dword [ebp + edx*4 - 0x5de8]
push eax
call fcn.004cfd5f
add esp, 4
jmp 0x401345
mov eax, dword [0x84cfa0]
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.004d0170
mov esp, ebp
pop ebp
ret 0x10