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

Disassembly:
sub esp, 0x11c
push ebx
push ebp
push esi
mov ebp, ecx
lea eax, [esp + 0x17]
push edi
lea edx, [esp + 0x13]
push eax
lea ecx, [ebp + 8]
push edx
mov dword [esp + 0x1c], ebp
mov byte [ebp + 4], 0
mov dword [ebp], 0x5fc8c0
call fcn.004245a0
lea esi, [ebp + 0x18]
mov dword [ebp + 0x14], 0
mov ecx, esi
call fcn.0040ee20
mov ecx, esi
call fcn.00416100
lea esi, [ebp + 0x24]
lea eax, [esp + 0x13]
push 8
push eax
mov ecx, esi
call fcn.00405da0
mov ecx, dword [esi + 4]
lea edx, [esp + 0x13]
push edx
mov byte [ecx], 0
lea ecx, [ebp + 0x34]
mov dword [ebp + 0x30], 4
call fcn.00405d90
mov dword [ebp], 0x5fcb08
mov eax, dword [str..cfg]
mov ecx, dword [str.scenar]
push eax
lea edx, [esp + 0xa4]
push ecx
push edx
call fcn.00415c00
add esp, 0xc
lea eax, [esp + 0x2c]
lea ecx, [esp + 0xa0]
push eax
call fcn.00470dc0
mov eax, dword [eax]
mov ecx, dword [esp + 0xa0]
cmp eax, ecx
mov dword [esp + 0x28], eax
je 0x4231d1
mov edi, dword [eax + 0x10]
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
cmp ecx, 0xc
ja 0x4231b1
lea ecx, [esp + 0x30]
call fcn.0040ee20
lea ecx, [esp + 0x30]
call fcn.00416100
mov ecx, dword [esp + 0x28]
mov edx, dword [ecx + 0x10]
lea ecx, [esp + 0x30]
push edx
call fcn.00415fc0
test al, al
je 0x4231a8
lea eax, [esp + 0x94]
lea ecx, [esp + 0x30]
push eax
call fcn.004165e0
mov eax, dword [esp + 0x94]
mov ecx, dword [esp + 0x98]
cmp eax, ecx
mov ebx, eax
je 0x42319c
lea ecx, [esp + 0x4c]
mov dword [esp + 0x1c], 0
call fcn.00405bc0
lea ecx, [esp + 0x58]
call fcn.00405bc0
lea ecx, [esp + 0x64]
call fcn.00405bc0
lea ecx, [esp + 0x13]
push ecx
lea ecx, [esp + 0x74]
call fcn.00405d90
mov eax, dword [str.name]
mov ecx, dword [ebx]
lea edx, [esp + 0x48]
push edx
push eax
push ecx
lea ecx, [esp + 0x3c]
call fcn.00416920
mov eax, dword [str.icon]
mov ecx, dword [ebx]
lea edx, [esp + 0x1c]
push edx
push eax
push ecx
lea ecx, [esp + 0x3c]
call fcn.004169f0
test al, al
je 0x422ead
mov edx, dword [esp + 0x1c]
test edx, edx
je 0x422ead
mov eax, dword [esp + 0x14]
mov edi, edx
push eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, edx
push ecx
push edx
lea ecx, [esp + 0x58]
call fcn.00406980
mov edx, dword [str.scenario]
mov eax, dword [ebx]
lea ecx, [esp + 0x1c]
push ecx
push edx
push eax
lea ecx, [esp + 0x3c]
call fcn.004169f0
test al, al
je 0x422eef
mov edx, dword [esp + 0x1c]
test edx, edx
je 0x422eef
mov ecx, dword [esp + 0x14]
mov edi, edx
push ecx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, edx
push ecx
push edx
lea ecx, [esp + 0x64]
call fcn.00406980
mov eax, dword [str.unlocks]
mov ecx, dword [ebx]
lea edx, [esp + 0x1c]
push edx
push eax
push ecx
lea ecx, [esp + 0x3c]
call fcn.004169f0
test al, al
je 0x422f30
mov edx, dword [esp + 0x1c]
test edx, edx
je 0x422f30
mov eax, dword [esp + 0x14]
mov edi, edx
push eax
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, edx
push ecx
push edx
lea ecx, [esp + 0x70]
call fcn.00406980
mov ecx, dword [str.locks]
mov edx, dword [ebx]
push ecx
lea eax, [esp + 0x80]
push edx
push eax
lea ecx, [esp + 0x3c]
call fcn.00416d70
mov ebp, dword [esp + 0x7c]
mov eax, dword [esp + 0x80]
cmp ebp, eax
je 0x422fef
mov esi, dword [ebp]
lea ecx, [esp + 0x1b]
push ecx
lea ecx, [esp + 0x8c]
call fcn.00405d90
mov edi, esi
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [esp + 0x14]
repne scasb al, byte es:[edi]
not ecx
dec ecx
push edx
add ecx, esi
push ecx
push esi
lea ecx, [esp + 0x94]
call fcn.004067a0
mov ecx, dword [esp + 0x74]
mov eax, dword [esp + 0x78]
cmp ecx, eax
je 0x422fbd
test ecx, ecx
je 0x422fb4
lea eax, [esp + 0x88]
push eax
call fcn.00407bf0
mov ecx, dword [esp + 0x74]
add ecx, 0xc
mov dword [esp + 0x74], ecx
jmp 0x422fd1
lea edx, [esp + 0x88]
push 1
push edx
push ecx
lea ecx, [esp + 0x7c]
call fcn.00424b00
lea ecx, [esp + 0x88]
call fcn.00406010
mov eax, dword [esp + 0x80]
add ebp, 4
cmp ebp, eax
jne 0x422f5e
mov ecx, dword [str.expansion]
mov edx, dword [ebx]
lea eax, [esp + 0x2c]
mov dword [esp + 0x2c], 0
push eax
push ecx
push edx
lea ecx, [esp + 0x3c]
call fcn.00416920
test al, al
je 0x423032
call fcn.0045e0e0
mov ax, word [eax + 0x444]
mov ecx, dword [esp + 0x2c]
and eax, 0xffff
and eax, ecx
cmp eax, ecx
jne 0x423159
mov esi, dword [ebx]
lea eax, [esp + 0x27]
push eax
lea ecx, [esp + 0x40]
call fcn.00405d90
mov ecx, dword [esp + 0x14]
mov edi, esi
push ecx
or ecx, 0xffffffff
xor eax, eax
repne scasb al, byte es:[edi]
not ecx
dec ecx
add ecx, esi
push ecx
push esi
lea ecx, [esp + 0x48]
call fcn.004067a0
mov ecx, dword [esp + 0x14]
lea edx, [esp + 0x3c]
lea eax, [esp + 0xb0]
push edx
lea esi, [ecx + 8]
push eax
mov ecx, esi
call fcn.004a2a90
mov edx, dword [eax]
lea eax, [esp + 0xac]
push eax
mov ecx, esi
mov dword [esp + 0x24], edx
call fcn.005d8060
mov ecx, eax
mov eax, dword [esp + 0x20]
cmp eax, dword [ecx]
je 0x4230af
add eax, 0x10
lea edx, [esp + 0x3c]
push eax
push edx
call fcn.00406410
add esp, 8
test al, al
je 0x423108
lea ecx, [esp + 0xb8]
call fcn.00423210
push eax
lea eax, [esp + 0x40]
push eax
lea ecx, [esp + 0xf4]
call fcn.00424660
push eax
push ecx
lea edx, [esp + 0x28]
mov ecx, esp
push edx
call fcn.005d82d0
lea eax, [esp + 0xbc]
mov ecx, esi
push eax
call fcn.00424570
mov ecx, dword [eax]
mov dword [esp + 0x20], ecx
lea ecx, [esp + 0xec]
call fcn.004244e0
lea ecx, [esp + 0xb8]
call fcn.004232a0
mov edx, dword [esp + 0x20]
mov eax, dword [esp + 0x48]
lea ecx, [esp + 0x4c]
mov dword [edx + 0x1c], eax
lea esi, [edx + 0x1c]
push ecx
lea ecx, [esi + 4]
call fcn.00407c80
lea edx, [esp + 0x58]
lea ecx, [esi + 0x10]
push edx
call fcn.00407c80
lea eax, [esp + 0x64]
lea ecx, [esi + 0x1c]
push eax
call fcn.00407c80
lea ecx, [esp + 0x70]
push ecx
lea ecx, [esi + 0x28]
call fcn.00424cd0
lea ecx, [esp + 0x3c]
call fcn.00406010
call dword [0x609ac0]
lea ecx, [esp + 0x7c]
call fcn.0040ee80
lea ecx, [esp + 0x70]
call fcn.0041d5f0
lea ecx, [esp + 0x64]
call fcn.00406010
lea ecx, [esp + 0x58]
call fcn.00406010
lea ecx, [esp + 0x4c]
call fcn.00406010
mov eax, dword [esp + 0x98]
add ebx, 4
cmp ebx, eax
jne 0x422e24
mov ebp, dword [esp + 0x14]
lea ecx, [esp + 0x94]
call fcn.0040ee80
lea ecx, [esp + 0x30]
call fcn.004248b0
lea edx, [esp + 0x28]
push edx
call fcn.004149c0
mov eax, dword [esp + 0x2c]
mov ecx, dword [esp + 0xa4]
add esp, 4
cmp eax, ecx
jne 0x422dba
lea ecx, [esp + 0xa0]
call fcn.00424470
pop edi
mov eax, ebp
pop esi
pop ebp
pop ebx
add esp, 0x11c
ret