Function at 0x4297f0
Capabilities:
Check if file exists
Get file attributes

Disassembly:
push 0xffffffffffffffff
push 0x4bdb67
mov eax, dword fs:[0]
push eax
sub esp, 0x38c
mov eax, dword [0x4f36a0]
xor eax, esp
mov dword [esp + 0x388], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x4f36a0]
xor eax, esp
push eax
lea eax, [esp + 0x3a0]
mov dword fs:[0], eax
mov esi, dword [esp + 0x3b4]
cmp word [esi], 0
mov eax, dword [esp + 0x3b8]
mov edi, dword [esp + 0x3b0]
mov ebx, edx
mov dword [esp + 0x2c], eax
mov dword [esp + 0x24], ecx
jne 0x429852
mov esi, edi
lea ecx, [esp + 0x154]
call fcn.00448930
mov eax, edi
lea edx, [esp + 0x154]
call fcn.00448b50
lea ecx, [esp + 0x278]
mov dword [esp + 0x3a8], 1
call fcn.00448930
mov eax, esi
lea edx, [esp + 0x278]
call fcn.00448b50
lea ecx, [esp + 0x30]
call fcn.00448930
mov ebp, str.sgim_core.bin
xor edx, edx
cmp edx, ebp
jne 0x4298aa
mov ebp, 0x4d6464
mov eax, ebp
lea edx, [eax + 2]
nop
mov cx, word [eax]
add eax, 2
test cx, cx
jne 0x4298b0
sub eax, edx
sar eax, 1
lea edi, [eax + 1]
mov ecx, edi
lea esi, [esp + 0x38]
mov dword [esp + 0x34], eax
call fcn.004495a0
cmp byte [esp + 0x14c], 0
lea eax, [esp + 0x3c]
jne 0x4298e3
mov eax, dword [esp + 0x38]
lea ecx, [edi + edi]
push ecx
add eax, 4
push ebp
push eax
call fcn.0049c670
mov byte [esp + 0x3b4], 3
mov cl, byte [esp + 0x158]
mov eax, dword [esp + 0x44]
add esp, 0xc
lea edx, [esp + 0x3c]
test cl, cl
jne 0x429911
mov edx, eax
mov edi, 0x2e
cmp word [edx + 4], di
jne 0x429971
test cl, cl
je 0x429924
lea eax, [esp + 0x3c]
mov ecx, dword [esp + 0x34]
lea esi, [eax + 4]
mov eax, dword [esp + 0x158]
cmp eax, ecx
jbe 0x429962
cmp byte [esp + 0x270], 0
lea edx, [esp + 0x160]
jne 0x42994e
mov edx, dword [esp + 0x15c]
sub eax, ecx
lea edx, [edx + eax*2 + 4]
push esi
push edx
call fcn.00498ec8
add esp, 8
test eax, eax
je 0x429982
push esi
lea eax, [esp + 0x158]
call fcn.00448d00
jmp 0x429982
lea eax, [esp + 0x30]
push eax
lea ecx, [esp + 0x158]
call fcn.00444630
cmp byte [esp + 0x14c], 0
mov ebp, vtable.t_str.0
mov dword [esp + 0x30], ebp
jne 0x4299aa
mov eax, dword [esp + 0x38]
lea ecx, [esp + 0x3c]
cmp eax, ecx
je 0x4299aa
push eax
call fcn.00498f5b
add esp, 4
push 0
push 0
push 0
push 0
push 0
push str.sgim_coreup.bin
lea ecx, [esp + 0x48]
call fcn.00443db0
cmp byte [esp + 0x14c], 0
lea eax, [esp + 0x3c]
jne 0x4299d4
mov eax, dword [esp + 0x38]
cmp word [eax + 4], di
jne 0x4299ec
lea ecx, [esp + 0x30]
lea esi, [esp + 0x278]
call fcn.00445030
jmp 0x4299fd
lea edx, [esp + 0x30]
push edx
lea ecx, [esp + 0x27c]
call fcn.00444630
cmp byte [esp + 0x14c], 0
mov dword [esp + 0x30], ebp
jne 0x429a20
mov eax, dword [esp + 0x38]
lea ecx, [esp + 0x3c]
cmp eax, ecx
je 0x429a20
push eax
call fcn.00498f5b
add esp, 4
xor eax, eax
cmp byte [esp + 0x394], al
mov dword [esp + 0x1c], eax
mov dword [esp + 0x18], eax
lea eax, [esp + 0x284]
jne 0x429a41
mov eax, dword [esp + 0x280]
mov edi, dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
add eax, 4
push eax
call edi
cmp eax, 0xffffffff
je 0x429b25
shr eax, 4
not al
and al, 1
je 0x429b25
call fcn.00429790
cmp byte [esp + 0x394], 0
lea eax, [esp + 0x284]
jne 0x429a80
mov eax, dword [esp + 0x280]
lea edx, [esp + 0x18]
push edx
lea ecx, [esp + 0x20]
push ecx
add eax, 4
push eax
mov esi, ebx
call fcn.0042b350
add esp, 0xc
test al, al
jne 0x429b02
push 0x4de1f4
push ebx
call fcn.004477d0
add esp, 8
cmp byte [esp + 0x394], 0
mov bl, al
mov dword [esp + 0x278], ebp
jne 0x429ad8
mov eax, dword [esp + 0x280]
lea edx, [esp + 0x284]
cmp eax, edx
je 0x429ad8
push eax
call fcn.00498f5b
add esp, 4
cmp byte [esp + 0x270], 0
mov dword [esp + 0x154], ebp
jne 0x429c80
mov eax, dword [esp + 0x15c]
lea ecx, [esp + 0x160]
cmp eax, ecx
jmp 0x429c75
mov esi, dword [esp + 0x18]
call fcn.00429790
cmp esi, 0x1328f5c
je 0x429b25
cmp esi, 0x132df0a
je 0x429b25
xor eax, eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
xor eax, eax
cmp byte [esp + 0x270], al
mov dword [esp + 0x28], eax
mov dword [esp + 0x20], eax
lea eax, [esp + 0x160]
jne 0x429b46
mov eax, dword [esp + 0x15c]
add eax, 4
push eax
call edi
cmp eax, 0xffffffff
je 0x429c18
shr eax, 4
not al
and al, 1
je 0x429c18
call fcn.00429790
cmp byte [esp + 0x270], 0
lea eax, [esp + 0x160]
jne 0x429b7f
mov eax, dword [esp + 0x15c]
lea edx, [esp + 0x20]
push edx
lea ecx, [esp + 0x2c]
push ecx
add eax, 4
push eax
mov esi, ebx
call fcn.0042b350
add esp, 0xc
test al, al
jne 0x429bc8
push 0x4de20c
push ebx
call fcn.004477d0
add esp, 8
lea ecx, [esp + 0x278]
mov bl, al
call fcn.004444f0
lea ecx, [esp + 0x154]
call fcn.004444f0
jmp 0x429c80
mov eax, dword [esp + 0x1c]
mov ecx, dword [esp + 0x28]
cmp eax, ecx
mov esi, dword [esp + 0x18]
jg 0x429bf0
mov edx, dword [esp + 0x20]
jne 0x429be2
cmp esi, edx
jg 0x429bf0
mov eax, dword [esp + 0x2c]
mov dword [eax], ecx
mov ecx, dword [esp + 0x24]
mov dword [ecx], edx
jmp 0x429bfc
mov edx, dword [esp + 0x2c]
mov dword [edx], eax
mov eax, dword [esp + 0x24]
mov dword [eax], esi
lea ecx, [esp + 0x278]
call fcn.004444f0
lea ecx, [esp + 0x154]
call fcn.004444f0
mov al, 1
jmp 0x429c82
push 0x4de228
push ebx
call fcn.004477d0
add esp, 8
cmp byte [esp + 0x394], 0
mov bl, al
mov dword [esp + 0x278], ebp
jne 0x429c54
mov eax, dword [esp + 0x280]
lea ecx, [esp + 0x284]
cmp eax, ecx
je 0x429c54
push eax
call fcn.00498f5b
add esp, 4
cmp byte [esp + 0x270], 0
mov dword [esp + 0x154], ebp
jne 0x429c80
mov eax, dword [esp + 0x15c]
lea edx, [esp + 0x160]
cmp eax, edx
je 0x429c80
push eax
call fcn.00498f5b
add esp, 4
mov al, bl
mov ecx, dword [esp + 0x3a0]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x388]
xor ecx, esp
call fcn.00497c58
add esp, 0x398
ret