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

Disassembly:
sub esp, 0xdb8
mov eax, dword [0x6a1068]
xor eax, esp
mov dword [esp + 0xdb4], eax
mov eax, dword [0x6dbb54]
push esi
push edi
mov edi, dword [esp + 0xdc4]
mov esi, ecx
push 0x400
lea ecx, [esp + 0x5c0]
push 0
push ecx
mov dword [esi + 4], eax
mov dword [esp + 0x14], 0
call fcn.00565680
add esp, 0xc
lea ecx, [esp + 0x68]
call fcn.00510050
push 0x10
push 0x5932a8
push edi
lea ecx, [esp + 0x74]
call fcn.00510de0
lea edx, [esp + 0x5bc]
push edx
lea ecx, [esp + 0x6c]
call fcn.00510590
cmp eax, 0xffffffff
je 0x530b1f
push ebx
push ebp
lea esp, [esp]
mov ebp, dword [sym.imp.KERNEL32.dll_lstrcmpA]
push str.GX_METADATA
lea eax, [esp + 0x5c8]
push eax
call ebp
test eax, eax
jne 0x53063c
push 0x590e58
lea ecx, [esp + 0x5c8]
push ecx
call ebp
test eax, eax
je 0x53063c
lea edx, [esp + 0x5c4]
push edx
lea ecx, [esp + 0x74]
call fcn.00510590
push str.BOX_MAX
lea eax, [esp + 0x5c8]
push eax
call ebp
test eax, eax
jne 0x5305ee
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esi + 0x10]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esi + 0x14]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esi + 0x18]
jmp 0x530625
push str.BOX_MIN
lea ecx, [esp + 0x5c8]
push ecx
call ebp
test eax, eax
jne 0x530625
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esi + 0x1c]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esi + 0x20]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esi + 0x24]
push 0x590e58
lea edx, [esp + 0x5c8]
push edx
call ebp
test eax, eax
jne 0x5305a4
push str.GX_MAP
lea eax, [esp + 0x5c8]
push eax
call ebp
test eax, eax
jne 0x530722
push 0x590e58
lea ecx, [esp + 0x5c8]
push ecx
call ebp
test eax, eax
je 0x530710
lea ebx, [ebx]
lea edx, [esp + 0x5c4]
push edx
lea ecx, [esp + 0x74]
call fcn.00510590
push str.STATIC_MODEL
lea eax, [esp + 0x5c8]
push eax
call ebp
test eax, eax
jne 0x5306bc
lea ecx, [esp + 0x5c4]
push ecx
lea ecx, [esp + 0x74]
call fcn.00510590
lea edx, [esp + 0x5c4]
push edx
mov ecx, esi
call fcn.00530450
mov dword [esp + 0x10], 1
push str.HEIGHT_FIELD
lea eax, [esp + 0x5c8]
push eax
call ebp
test eax, eax
jne 0x5306f9
lea ecx, [esp + 0x5c4]
push ecx
lea ecx, [esp + 0x74]
call fcn.00510590
push 0
lea edx, [esp + 0x5c8]
push edx
mov ecx, esi
call fcn.00530300
mov dword [esp + 0x10], 1
push 0x590e58
lea eax, [esp + 0x5c8]
push eax
call ebp
test eax, eax
jne 0x530670
cmp dword [esp + 0x10], 0
je 0x530722
lea ecx, [esi + 0x10]
push ecx
mov ecx, esi
call fcn.00530130
push str.GX_OBJECT
lea edx, [esp + 0x5c8]
push edx
call ebp
test eax, eax
jne 0x530945
lea ecx, [esp + 0x70]
call fcn.00511030
mov edi, eax
lea eax, [esp + 0x5c4]
push eax
lea ecx, [esp + 0x74]
call fcn.00510590
test edi, edi
je 0x530934
mov dword [esp + 0x14], edi
lea ecx, [esp + 0x5c4]
push ecx
lea ecx, [esp + 0x74]
call fcn.00510590
lea ecx, [esp + 0x70]
call fcn.00511030
lea ecx, [esp + 0x70]
mov ebx, eax
call fcn.00511010
fstp dword [esp + 0x4c]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x50]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x54]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x58]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x5c]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x60]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x64]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x68]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x6c]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x1c]
lea edx, [esp + 0x18]
push edx
lea ecx, [esp + 0x74]
call fcn.005102b0
mov edx, dword [esp + 0x18]
mov eax, dword [esi + 4]
mov ecx, dword [eax]
push edx
push 0
push 0
lea edx, [esp + 0x5d0]
push edx
push eax
mov eax, dword [ecx + 0x18c]
call eax
mov edi, eax
test edi, edi
jne 0x530854
lea ecx, [esp + 0x5c4]
push ecx
lea edx, [esp + 0x9c8]
push str.Failed_to_load_MapObject___s_
push edx
call fcn.00565b90
add esp, 0xc
jmp 0x53092a
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x4c]
push 0
push edi
push eax
call edx
test eax, eax
je 0x530899
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x1cc]
push edi
push eax
call edx
mov edx, dword [esp + 0x18]
mov eax, dword [esi + 4]
mov ecx, dword [eax]
or edx, 8
push edx
push 0
push 0
lea edx, [esp + 0x5d0]
push edx
push eax
mov eax, dword [ecx + 0x18c]
call eax
mov edi, eax
test edi, edi
je 0x53092a
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x150]
push ebx
push edi
push eax
call edx
mov eax, dword [esi + 4]
mov ecx, dword [eax]
lea edx, [esp + 0x4c]
push edx
push edi
push eax
mov eax, dword [ecx + 0x8c]
call eax
mov eax, dword [esi + 4]
mov ecx, dword [eax]
push 0
lea edx, [esp + 0x5c]
push edx
push edi
push eax
mov eax, dword [ecx + 0x64]
call eax
fld dword [esp + 0x1c]
mov eax, dword [esi + 4]
mov ecx, dword [eax]
push ecx
fstp dword [esp]
lea edx, [esp + 0x68]
push edx
push edi
push eax
mov eax, dword [ecx + 0x78]
call eax
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x180]
push edi
push eax
call edx
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x178]
push edi
push eax
call edx
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x170]
push edi
push eax
call edx
push edi
lea ecx, [esi + 0x1a0]
call fcn.00560560
dec dword [esp + 0x14]
jne 0x530761
lea eax, [esp + 0x5c4]
push eax
lea ecx, [esp + 0x74]
call fcn.00510590
push str.GX_LIGHT
lea ecx, [esp + 0x5c8]
push ecx
call ebp
test eax, eax
jne 0x530983
lea ecx, [esp + 0x70]
call fcn.00511030
lea edx, [esp + 0x5c4]
push edx
lea ecx, [esp + 0x74]
call fcn.00510590
lea eax, [esp + 0x5c4]
push eax
lea ecx, [esp + 0x74]
call fcn.00510590
push 0x595c08
lea ecx, [esp + 0x5c8]
push ecx
call ebp
test eax, eax
jne 0x530b03
lea ecx, [esp + 0x70]
call fcn.00511030
lea edx, [esp + 0x5c4]
push edx
lea ecx, [esp + 0x74]
mov ebp, eax
call fcn.00510590
test ebp, ebp
je 0x530af2
mov edi, edi
xor eax, eax
lea ecx, [esp + 0x70]
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], 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
call fcn.00511030
mov ebx, eax
lea eax, [esp + 0x48]
push eax
lea ecx, [esp + 0x74]
call fcn.005102b0
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x24]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x28]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x2c]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x30]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x34]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x38]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x3c]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x40]
lea ecx, [esp + 0x70]
call fcn.00511010
fstp dword [esp + 0x44]
lea ecx, [esp + 0x20]
push ecx
lea ecx, [esp + 0x74]
call fcn.005102b0
mov ecx, dword [esp + 0x20]
mov eax, dword [esi + 4]
mov edx, dword [eax]
mov edx, dword [edx + 0x194]
push ecx
push 0
push 0
push eax
call edx
mov edi, eax
mov eax, dword [esi + 4]
mov ecx, dword [eax]
mov edx, dword [ecx + 0x150]
push ebx
push edi
push eax
call edx
mov eax, dword [esi + 4]
mov ecx, dword [eax]
lea edx, [esp + 0x24]
push edx
push edi
push eax
mov eax, dword [ecx + 0x210]
call eax
mov eax, dword [esi + 4]
mov ecx, dword [eax]
lea edx, [esp + 0x30]
push edx
push edi
push eax
mov eax, dword [ecx + 0x214]
call eax
mov eax, dword [esi + 4]
mov ecx, dword [eax]
lea edx, [esp + 0x3c]
push edx
push edi
push eax
mov eax, dword [ecx + 0x218]
call eax
dec ebp
jne 0x5309c0
lea ecx, [esp + 0x5c4]
push ecx
lea ecx, [esp + 0x74]
call fcn.00510590
lea edx, [esp + 0x5c4]
push edx
lea ecx, [esp + 0x74]
call fcn.00510590
cmp eax, 0xffffffff
jne 0x530570
pop ebp
pop ebx
lea ecx, [esp + 0x68]
call fcn.00510140
mov esi, dword [esi + 8]
lea ecx, [esp + 0x68]
call fcn.00510560
mov ecx, dword [esp + 0xdbc]
pop edi
mov eax, esi
pop esi
xor ecx, esp
call fcn.00565c32
add esp, 0xdb8
ret 4