Function at 0x40bd10
Capabilities:
Set current directory

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x461cc2
push eax
mov dword fs:[0], esp
sub esp, 0x134
push ebp
mov ebp, dword [esp + 0x148]
push esi
mov esi, ecx
mov eax, dword [esi + 0x204]
cmp eax, 6
push edi
jne 0x40bdfb
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x18], esp
push eax
mov ecx, ebp
call fcn.00425590
call fcn.0040d650
add esp, 0xc
cmp eax, 7
jne 0x40bdfb
mov ecx, dword [esi + 0x1f4]
mov eax, dword [ecx + 0xa14]
push eax
lea edx, [esp + 0x18]
push 0x12c
push edx
call fcn.00446a3e
lea eax, [esp + 0x20]
add esp, 0xc
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x40bd90
sub eax, edx
cmp eax, 3
jge 0x40bdaf
mov ecx, 0x492500
call fcn.004199a0
jmp case.default.0x40bf3a
cmp eax, 4
jle 0x40bdc2
cmp byte [esp + eax + 0x13], 0x5c
lea eax, [esp + eax + 0x13]
jne 0x40bdc2
mov byte [eax], 0
sub esp, 0xc
lea eax, [esp + 0x20]
mov ecx, esp
mov dword [esp + 0x18], esp
push eax
call fcn.00421f00
call fcn.00403bd0
add esp, 0xc
lea ecx, [esp + 0x14]
push ecx
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
test eax, eax
je 0x40bda0
lea edx, [esp + 0x14]
push edx
mov ecx, 0x4924f4
call fcn.00422070
push 1
push 0x3e9
mov ecx, esi
mov byte [esi + 0x180], 1
call fcn.0042a817
mov ecx, eax
call fcn.0042aa14
mov eax, dword [esi + 0x204]
add eax, 0xffffffff
cmp eax, 6
ja case.default.0x40be29
jmp dword [eax*4 + 0x40c1ac]
mov ecx, dword [esi + 0x1e4]
call fcn.00429630
jmp case.default.0x40be29
mov ecx, dword [esi + 0x1e8]
call fcn.0041cb70
jmp case.default.0x40be29
mov ecx, dword [esi + 0x1ec]
call fcn.004206a0
jmp case.default.0x40be29
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x18], esp
push 4
push eax
call fcn.0040d190
add esp, 8
call fcn.0040aab0
mov ecx, esp
mov dword [esp + 0x18], esp
push ecx
mov ecx, ebp
mov edi, eax
call fcn.00425590
call fcn.0040aab0
add esp, 0xc
cmp eax, edi
jle 0x40bea8
mov ecx, dword [esi + 0x1f0]
call fcn.0041df10
test al, al
je 0x40bda0
mov ecx, dword [esi + 0x1f0]
call fcn.0041d620
mov ecx, dword [esi + 0x1f0]
call fcn.0041d3b0
jmp case.default.0x40be29
mov ecx, dword [esi + 0x1f4]
call fcn.004011a0
jmp case.default.0x40be29
mov edx, dword [esi + 0x1f8]
add edx, 0x188
push edx
mov ecx, 0x48712c
call fcn.00421e20
mov ecx, dword [esi + 0x1f8]
call fcn.0041f9c0
jmp case.default.0x40be29
mov ecx, dword [esi + 0x1fc]
call fcn.00418c10
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x18], esp
push eax
mov ecx, ebp
call fcn.00425590
call fcn.0040d650
mov ecx, esp
mov dword [esp + 0x18], esp
push ecx
mov ecx, ebp
mov dword [esi + 0x204], eax
call fcn.00425590
call fcn.0040d650
sub eax, 1
add esp, 0xc
cmp eax, 6
ja case.default.0x40bf3a
jmp dword [eax*4 + 0x40c1c8]
mov ecx, dword [esi + 0x1e4]
mov byte [esi + 0x180], 0
call fcn.00429620
jmp case.default.0x40bf3a
mov ecx, dword [esi + 0x1e8]
sub esp, 0xc
mov edx, esp
mov dword [esp + 0x18], esp
push edx
call fcn.0041cb00
mov ecx, dword [esi + 0x1e8]
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x28], esp
push eax
mov dword [esp + 0x164], 0
call fcn.0041cad0
mov ecx, esi
mov dword [esp + 0x160], 0xffffffff
call fcn.0040bc90
cmp byte [0x487025], 0
jne 0x40bfbd
push 0
push 0x3e9
mov ecx, esi
call fcn.0042a817
mov ecx, eax
call fcn.0042aa14
mov ecx, dword [esi + 0x1e8]
call fcn.0041cb30
jmp case.default.0x40bf3a
sub esp, 0xc
mov ecx, esp
mov dword [esp + 0x1c], esp
push ecx
mov ecx, dword [esi + 0x1ec]
call fcn.00420660
mov ecx, dword [esi + 0x1ec]
sub esp, 0xc
mov edx, esp
mov dword [esp + 0x24], esp
push edx
mov dword [esp + 0x164], 1
call fcn.00420630
mov ecx, esi
mov dword [esp + 0x160], 0xffffffff
call fcn.0040bc90
mov ecx, dword [esi + 0x1ec]
call fcn.00420690
jmp case.default.0x40bf3a
mov ecx, dword [esi + 0x1f0]
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x1c], esp
push eax
call fcn.0041d5e0
sub esp, 0xc
mov ecx, esp
mov dword [esp + 0x24], esp
push ecx
mov ecx, dword [esi + 0x1f0]
mov dword [esp + 0x164], 2
call fcn.0041d5b0
mov ecx, esi
mov dword [esp + 0x160], 0xffffffff
call fcn.0040bc90
mov ecx, dword [esi + 0x1f0]
call fcn.0041d610
jmp case.default.0x40bf3a
mov ecx, dword [esi + 0x1f4]
sub esp, 0xc
mov edx, esp
mov dword [esp + 0x1c], esp
push edx
call fcn.00401150
mov ecx, dword [esi + 0x1f4]
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x24], esp
push eax
mov dword [esp + 0x164], 3
call fcn.00401120
mov ecx, esi
mov dword [esp + 0x160], 0xffffffff
call fcn.0040bc90
mov ecx, dword [esi + 0x1f4]
call fcn.00401190
jmp case.default.0x40bf3a
sub esp, 0xc
mov ecx, esp
mov dword [esp + 0x1c], esp
push ecx
mov ecx, dword [esi + 0x1f8]
call fcn.0041f970
mov ecx, dword [esi + 0x1f8]
sub esp, 0xc
mov edx, esp
mov dword [esp + 0x24], esp
push edx
mov dword [esp + 0x164], 4
call fcn.0041f940
mov ecx, esi
mov dword [esp + 0x160], 0xffffffff
call fcn.0040bc90
mov ecx, dword [esi + 0x1f8]
call fcn.0041f9b0
jmp case.default.0x40bf3a
mov ecx, dword [esi + 0x1fc]
sub esp, 0xc
mov eax, esp
mov dword [esp + 0x1c], esp
push eax
call fcn.00418b60
sub esp, 0xc
mov ecx, esp
mov dword [esp + 0x24], esp
push ecx
mov ecx, dword [esi + 0x1fc]
mov dword [esp + 0x164], 5
call fcn.00418b30
mov ecx, esi
mov dword [esp + 0x160], 0xffffffff
call fcn.0040bc90
push 0
lea ecx, [esi + 0x11c]
call fcn.0042aa14
push 0
lea ecx, [esi + 0xc8]
call fcn.0042aa14
mov ecx, dword [esi + 0x1fc]
call fcn.00418ba0
mov ecx, dword [esp + 0x140]
pop edi
pop esi
mov dword fs:[0], ecx
pop ebp
add esp, 0x140
ret 4