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

Disassembly:
sub esp, 0x74
mov eax, dword [esp + 0x84]
push ebx
push ebp
push esi
mov eax, dword [eax]
mov esi, dword [esp + 0x84]
push edi
push esi
mov dword [esp + 0x1c], 0
mov dword [esp + 0x38], eax
call fcn.004b9310
mov dword [esp + 0x48], eax
xor edi, edi
xor eax, eax
mov dword [esp + 0x2c], 0
mov dword [esp + 0x60], eax
xor ebx, ebx
mov eax, dword [esp + 0xa0]
mov dword [esp + 0x20], ebx
mov eax, dword [eax]
mov dword [esp + 0x84], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x4c], eax
lea eax, [esp + 0x1c]
push eax
push edi
push 7
push edi
push 0xc
push dword [esp + 0xbc]
call fcn.004bb420
add esp, 0x1c
mov ebp, eax
mov dword [esp + 0x20], ebp
cmp dword [esp + 0x18], ebx
jne 0x5076fb
push 2
push esi
call fcn.004b99f0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9870
add esp, 8
movzx eax, ax
mov dword [esp + 0x60], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9870
add esp, 8
movzx eax, ax
mov dword [esp + 0x68], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9870
add esp, 8
movzx eax, ax
mov dword [esp + 0x54], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
mov edx, dword [esp + 0xa0]
xor ecx, ecx
mov eax, dword [esp + 0x68]
mov word [edx + 4], ax
movzx eax, ax
mov dword [esp + 0x2c], eax
inc eax
cmp word [esp + 0x54], cx
setne cl
lea ecx, [ecx*2 + 2]
imul ecx, eax
mov eax, dword [edx + 0x10]
cmp dword [eax + 8], ecx
jne 0x5076f3
mov eax, dword [edx + 0xc]
mov dword [esp + 0x50], 0x24
cmp dword [eax + 0xc], 0x24
jb 0x5076f3
mov dword [esp + 0x4c], ebx
add ebp, 8
nop dword [eax]
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b96d0
add esp, 8
mov dword [esp + 0x64], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
mov ecx, dword [esp + 0xa0]
mov edx, dword [esp + 0x50]
mov ecx, dword [ecx + 0xc]
mov ecx, dword [ecx + 0xc]
sub ecx, edx
cmp eax, ecx
ja 0x5076f3
mov eax, dword [esp + 0x44]
add eax, edx
mov dword [ebp - 8], eax
mov dword [ebp - 4], eax
mov eax, dword [esp + 0x64]
add edx, eax
mov dword [ebp], eax
add ebp, 0xc
mov eax, dword [esp + 0x4c]
inc eax
mov dword [esp + 0x50], edx
mov dword [esp + 0x4c], eax
cmp eax, 7
jb 0x506d80
test byte [esp + 0x60], 1
mov ebp, dword [esp + 0x2c]
je 0x506e13
mov eax, dword [esp + 0xa0]
mov eax, dword [eax + 0xc]
mov ecx, dword [eax + 0xc]
lea eax, [ebp + 7]
sub ecx, edx
shr eax, 3
cmp eax, ecx
ja 0x5076ec
mov eax, dword [esp + 0x44]
add eax, edx
mov dword [esp + 0x5c], eax
lea eax, [esp + 0x18]
push eax
push 0
lea eax, [ebp + 1]
push eax
push 0
push 4
push dword [esp + 0xb8]
call fcn.004bb420
add esp, 0x18
mov dword [esp + 0x28], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
mov ecx, dword [esp + 0x2c]
mov eax, 0x1400
mov ebp, dword [esp + 0x20]
mov dword [esp + 0x38], eax
lea eax, [esp + 0x18]
push eax
lea ecx, [ecx + 0x1f]
mov edx, dword [ebp + 0x40]
shr ecx, 3
and ecx, 0x1ffffffc
mov dword [esp + 0x70], edx
push 0x1400
push dword [esp + 0xac]
add ecx, edx
mov dword [ebp + 0x40], ecx
call fcn.004bb3d0
add esp, 0xc
mov dword [esp + 0x1c], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
lea eax, [esp + 0x18]
push eax
push 0
push dword [esp + 0x34]
push 0
push 2
push dword [esp + 0xb8]
call fcn.004bb420
mov edx, dword [esp + 0xb8]
add esp, 0x18
mov dword [edx + 8], eax
cmp dword [esp + 0x18], ebx
jne 0x5076fb
xor ebx, ebx
mov dword [esp + 0x50], ebx
cmp dword [esp + 0x2c], ebx
jbe 0x50774a
xor eax, eax
mov edi, ebx
mov dword [esp + 0x44], eax
xor ebp, ebp
mov dword [esp + 0x3c], eax
mov eax, dword [esp + 0x6c]
shr edi, 3
add eax, edi
push eax
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9420
add esp, 8
mov dl, al
cmp dword [esp + 0x18], ebp
jne 0x5076e8
mov ecx, ebx
mov eax, 0x80
mov ebx, dword [esp + 0x20]
and ecx, 7
sar eax, cl
movzx ecx, dl
and ecx, eax
mov dword [esp + 0x58], eax
push dword [ebx + 4]
mov dword [esp + 0x50], ecx
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9870
add esp, 8
movzx eax, ax
mov dword [esp + 0x24], eax
cmp dword [esp + 0x18], ebp
jne 0x5076e8
add dword [ebx + 4], 2
mov ecx, 0xffff
cmp ax, cx
jne 0x5071fa
xor edi, edi
mov dword [esp + 0x3c], ebp
xor bl, bl
mov dword [esp + 0x58], edi
mov byte [esp + 0x12], bl
cmp dword [esp + 0x4c], edi
je 0x5076e8
mov ebp, dword [esp + 0x20]
xor al, al
mov dword [esp + 0x24], edi
mov byte [esp + 0x13], al
mov ecx, dword [ebp + 0x34]
push ecx
push esi
mov dword [esp + 0x6c], ecx
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x24], eax
test eax, eax
jne 0x5076e8
lea eax, [esp + 0x24]
push eax
push esi
call fcn.004b9870
movzx ebx, ax
add esp, 8
mov eax, dword [esp + 0x24]
test eax, eax
jne 0x507048
mov eax, ebx
shr eax, 8
and al, 1
or byte [esp + 0x13], al
mov eax, ebx
and eax, 1
lea eax, [eax*2 + 4]
test bl, 8
je 0x506ffd
add eax, 2
jmp 0x50700e
test bl, 0x40
je 0x507007
add eax, 4
jmp 0x50700e
test bl, bl
jns 0x50700e
add eax, 8
push eax
push esi
call fcn.004b99f0
add esp, 8
mov dword [esp + 0x24], eax
test eax, eax
jne 0x507048
test bl, 0x20
jne 0x506fc3
push esi
call fcn.004b9310
mov edi, eax
add esp, 4
mov al, byte [esp + 0x13]
sub edi, dword [esp + 0x64]
mov bl, al
mov byte [esp + 0x12], al
mov eax, dword [esp + 0x24]
mov dword [esp + 0x58], edi
jmp 0x50704c
mov bl, byte [esp + 0x12]
test eax, eax
jne 0x5076e8
test bl, bl
je 0x507096
push dword [ebp + 0x28]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
lea eax, [esp + 0x3c]
push eax
push esi
call fcn.00504000
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
push esi
call fcn.004b9310
add esp, 4
mov dword [ebp + 0x28], eax
mov eax, dword [esp + 0x3c]
add edi, 0xc
movzx ebx, ax
mov eax, dword [esp + 0x38]
add edi, ebx
cmp eax, edi
jae 0x5070dc
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esp + 0x20]
push ecx
push edi
push eax
push 1
push dword [esp + 0xb8]
call fcn.004bb420
add esp, 0x18
mov dword [esp + 0x1c], eax
cmp dword [esp + 0x18], 0
jne 0x5076e8
mov dword [esp + 0x38], edi
jmp 0x5070e0
mov eax, dword [esp + 0x1c]
mov word [eax], 0xffff
push dword [ebp + 0x40]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9870
add esp, 8
movzx eax, ax
cmp dword [esp + 0x18], 0
mov dword [esp + 0x44], eax
jne 0x5076e8
push dword [ebp + 0x40]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
mov eax, dword [esp + 0x1c]
push 8
add eax, 2
push eax
push esi
call fcn.004b9320
add esp, 0xc
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
push dword [ebp + 0x34]
add dword [ebp + 0x40], 8
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
mov eax, dword [esp + 0x1c]
mov edi, dword [esp + 0x58]
add eax, 0xa
push edi
push eax
push esi
call fcn.004b9320
add esp, 0xc
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
add dword [ebp + 0x34], edi
lea ebp, [edi + 0xa]
cmp byte [esp + 0x12], al
je 0x5071f3
mov ecx, dword [esp + 0x3c]
mov eax, ecx
mov edx, dword [esp + 0x1c]
mov edi, dword [esp + 0x20]
shr eax, 8
mov byte [edx + ebp], al
mov byte [edx + ebp + 1], cl
add ebp, 2
push dword [edi + 0x4c]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
mov eax, dword [esp + 0x1c]
push ebx
add eax, ebp
push eax
push esi
call fcn.004b9320
add esp, 0xc
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
add dword [edi + 0x4c], ebx
add ebp, ebx
xor ebx, ebx
jmp 0x507631
test ax, ax
je 0x507625
mov ecx, dword [esp + 0x5c]
xor ebp, ebp
xor bl, bl
mov dword [esp + 0x64], ebp
mov byte [esp + 0x60], bl
test ecx, ecx
je 0x50725f
lea eax, [edi + ecx]
push eax
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076e8
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9420
add esp, 8
cmp dword [esp + 0x18], ebp
jne 0x5076e8
test byte [esp + 0x58], al
mov ecx, 1
movzx eax, bl
cmovne eax, ecx
mov byte [esp + 0x60], al
mov eax, dword [esp + 0x24]
lea ecx, [esp + 0x18]
movzx eax, ax
push ecx
push 0
push eax
push 0
push 2
push dword [esp + 0xb8]
call fcn.004bb420
add esp, 0x18
mov ebx, eax
cmp dword [esp + 0x18], ebp
jne 0x5076ea
mov ecx, dword [esp + 0x20]
push dword [ecx + 0x10]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
xor edi, edi
test eax, eax
jne 0x5076ec
cmp word [esp + 0x24], di
je 0x5072f2
nop
lea eax, [esp + 0x14]
push eax
push esi
call fcn.00504000
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ea
mov ax, word [esp + 0x14]
mov word [ebx + edi*2], ax
movzx eax, ax
add eax, ebp
cmp eax, ebp
jb 0x5076ea
mov ecx, dword [esp + 0x24]
mov ebp, eax
inc edi
movzx eax, cx
mov dword [esp + 0x64], ebp
cmp edi, eax
jb 0x5072b0
push esi
call fcn.004b9310
mov ecx, dword [esp + 0x24]
add esp, 4
mov dword [ecx + 0x10], eax
cmp ebp, dword [ecx + 0x20]
ja 0x5076ea
mov edx, dword [esi]
mov eax, dword [ecx + 0x1c]
add eax, edx
mov dword [esp + 0x78], edx
mov edx, dword [ecx + 0x24]
mov dword [esp + 0x7c], eax
mov eax, dword [ecx + 0x28]
mov ecx, dword [ecx + 0x2c]
mov dword [esp + 0x70], eax
sub eax, edx
mov dword [esp + 0x44], edx
mov dword [esp + 0x74], ecx
cmp ecx, eax
jb 0x5076ea
lea eax, [esp + 0x18]
mov dword [esp + 0x58], 0
push eax
push 0
push ebp
push 0
push 0xc
push dword [esp + 0xb8]
call fcn.004bb420
add esp, 0x18
mov edi, eax
cmp dword [esp + 0x18], 0
jne 0x5076fb
lea eax, [esp + 0x58]
push eax
mov eax, dword [esp + 0x48]
sub eax, dword [esp + 0x74]
add eax, dword [esp + 0x78]
push edi
push ebp
push eax
mov eax, dword [esp + 0x88]
add eax, dword [esp + 0x80]
push eax
push dword [esp + 0x90]
call fcn.00508620
add esp, 0x18
test eax, eax
jne 0x5076ec
mov ecx, dword [esp + 0x20]
mov eax, dword [esp + 0x58]
add dword [ecx + 0x28], eax
push dword [ecx + 0x28]
add dword [ecx + 0x1c], ebp
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
lea eax, [esp + 0x40]
push eax
push esi
call fcn.00504000
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
push esi
call fcn.004b9310
mov ecx, dword [esp + 0x24]
add esp, 4
mov dword [ecx + 0x28], eax
cmp ebp, 0x8000000
jae 0x5076ec
mov ecx, dword [esp + 0x40]
mov edx, dword [esp + 0x24]
movzx eax, cx
add eax, ebp
movzx ecx, dx
mov edx, dword [esp + 0x38]
lea eax, [eax + ebp*4]
lea eax, [eax + ecx*2]
add eax, 0xc
mov dword [esp + 0x7c], eax
cmp edx, eax
jae 0x50745c
lea ecx, [esp + 0x18]
push ecx
mov ecx, dword [esp + 0x20]
push ecx
push eax
push edx
push 1
push dword [esp + 0xb8]
call fcn.004bb420
add esp, 0x18
mov edx, eax
cmp dword [esp + 0x18], 0
mov dword [esp + 0x1c], edx
jne 0x5076fb
mov eax, dword [esp + 0x7c]
mov dword [esp + 0x38], eax
jmp 0x507460
mov edx, dword [esp + 0x1c]
mov ecx, dword [esp + 0x24]
mov eax, ecx
shr eax, 8
cmp dword [esp + 0x4c], 0
mov byte [edx], al
mov byte [edx + 1], cl
je 0x5074ee
mov ebp, dword [esp + 0x20]
push dword [ebp + 0x40]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
lea eax, [esp + 0x18]
push eax
push esi
call fcn.004b9870
add esp, 8
movzx eax, ax
cmp dword [esp + 0x18], 0
mov dword [esp + 0x44], eax
jne 0x5076fb
push dword [ebp + 0x40]
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
mov eax, dword [esp + 0x1c]
push 8
add eax, 2
push eax
push esi
call fcn.004b9320
add esp, 0xc
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
add dword [ebp + 0x40], 8
jmp 0x507506
lea eax, [esp + 0x3c]
push eax
push edx
push edi
push ebp
call fcn.005043e0
mov eax, dword [esp + 0x4c]
add esp, 0x10
mov dword [esp + 0x44], eax
mov edx, dword [esp + 0x1c]
xor ebp, ebp
mov esi, dword [esp + 0x88]
add edx, 0xa
or ecx, 0xffffffff
mov dword [esp + 0x3c], 0xa
cmp word [esp + 0x24], bp
je 0x507567
mov dword [esp + 0x3c], 0xa
movzx eax, word [ebx + ebp*2]
add ecx, eax
cmp ecx, 0x10000
jge 0x5076ec
mov esi, dword [esp + 0x24]
mov eax, ecx
add dword [esp + 0x3c], 2
inc ebp
sar eax, 8
mov byte [edx], al
movzx eax, si
mov esi, dword [esp + 0x88]
mov byte [edx + 1], cl
add edx, 2
cmp ebp, eax
jb 0x507530
mov ecx, dword [esp + 0x40]
mov eax, ecx
mov ebp, dword [esp + 0x20]
shr eax, 8
mov byte [edx], al
mov eax, dword [esp + 0x3c]
mov byte [edx + 1], cl
add eax, 2
push dword [ebp + 0x4c]
mov dword [esp + 0x5c], eax
push esi
call fcn.004b99b0
add esp, 8
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
mov ecx, dword [esp + 0x40]
movzx eax, cx
push eax
mov eax, dword [esp + 0x5c]
add eax, dword [esp + 0x20]
push eax
push esi
call fcn.004b9320
add esp, 0xc
mov dword [esp + 0x18], eax
test eax, eax
jne 0x5076ec
mov edx, dword [esp + 0x40]
mov eax, dword [esp + 0x58]
movzx ecx, dx
add dword [ebp + 0x4c], ecx
add eax, ecx
mov dword [esp + 0x58], eax
lea eax, [esp + 0x58]
push eax
mov eax, dword [esp + 0x3c]
push eax
push dword [esp + 0x24]
push dword [esp + 0x6c]
push edx
push dword [esp + 0x38]
push edi
push dword [esp + 0x80]
call fcn.005083c0
add esp, 0x20
test eax, eax
jne 0x5076ec
mov ebp, dword [esp + 0xa4]
push edi
push ebp
call fcn.004bb3b0
push ebx
push ebp
call fcn.004bb3b0
mov ebp, dword [esp + 0x68]
add esp, 0x10
xor ebx, ebx
jmp 0x507631
xor ebx, ebx
cmp dword [esp + 0x4c], ebx
jne 0x5076e8
push dword [esp + 0xa4]
mov eax, dword [esp + 0x54]
mov edi, ebx
mov edx, dword [esp + 0x2c]
mov ecx, dword [esp + 0x34]
sub ecx, dword [esp + 0x84]
push ebp
push dword [esp + 0x24]
mov dword [edx + eax*4], ecx
lea eax, [esp + 0x54]
push eax
push dword [esp + 0xa8]
lea eax, [esp + 0x48]
push eax
call fcn.0050c170
add esp, 0x18
test eax, eax
jne 0x5076ec
push dword [esp + 0xa4]
lea eax, [esp + 0x4c]
push eax
push dword [esp + 0xa0]
lea eax, [esp + 0x40]
push eax
call fcn.005054f0
add esp, 0x10
test eax, eax
jne 0x5076ec
push ebp
push dword [esp + 0x20]
call fcn.00504340
mov ecx, dword [esp + 0x94]
add esp, 8
mov edx, dword [esp + 0xa0]
mov ebx, dword [esp + 0x50]
add dword [ecx], eax
mov eax, dword [edx + 8]
mov ecx, dword [esp + 0x44]
mov word [eax + ebx*2], cx
inc ebx
mov dword [esp + 0x50], ebx
cmp ebx, dword [esp + 0x2c]
jae 0x5076da
mov eax, dword [esp + 0x48]
mov dword [esp + 0x30], eax
jmp 0x506ed1
mov esi, dword [esp + 0x48]
mov ebp, dword [esp + 0x20]
mov dword [esp + 0x30], esi
jmp 0x50774e
xor ebx, ebx
xor edi, edi
cmp dword [esp + 0x18], 0
jne 0x5076fb
mov dword [esp + 0x18], 8
mov ecx, dword [esp + 0x94]
push dword [esp + 0x20]
mov eax, dword [esp + 0x38]
mov esi, dword [esp + 0xa8]
push esi
mov dword [ecx], eax
call fcn.004bb3b0
push dword [esp + 0x30]
push esi
call fcn.004bb3b0
push ebx
push esi
call fcn.004bb3b0
push dword [esp + 0x34]
push esi
call fcn.004bb3b0
push edi
push esi
call fcn.004bb3b0
mov eax, dword [esp + 0x40]
add esp, 0x28
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x74
ret
mov esi, dword [esp + 0x30]
mov ecx, dword [edx + 0xc]
mov eax, esi
mov dword [esp + 0x38], 0
mov dword [esp + 0x64], esi
sub eax, dword [ecx + 0x1c]
mov dword [ecx + 8], eax
mov eax, dword [edx + 0x10]
mov dword [eax + 0x1c], esi
mov eax, dword [esp + 0x68]
movzx ecx, ax
mov eax, dword [edx + 0xc]
mov edx, dword [esp + 0x28]
lea edi, [ecx + 1]
mov eax, dword [eax + 8]
mov dword [edx + ecx*4], eax
lea ecx, [esp + 0x38]
mov eax, dword [esp + 0x34]
mov dword [esp + 0x68], eax
xor eax, eax
cmp word [esp + 0x54], ax
push ecx
setne al
lea eax, [eax*2 + 2]
imul eax, edi
push eax
push dword [esp + 0xac]
mov dword [esp + 0x8c], eax
call fcn.004bb3d0
add esp, 0xc
mov ebx, eax
cmp dword [esp + 0x38], 0
jne 0x507891
xor esi, esi
mov edx, ebx
test edi, edi
je 0x50782d
mov ebp, dword [esp + 0x28]
cmp word [esp + 0x54], si
je 0x507809
nop word [eax + eax]
mov ecx, dword [ebp + esi*4]
lea edx, [edx + 4]
mov eax, ecx
inc esi
shr eax, 0x18
mov byte [edx - 4], al
mov eax, ecx
shr eax, 0x10
mov byte [edx - 3], al
mov eax, ecx
shr eax, 8
mov byte [edx - 2], al
mov byte [edx - 1], cl
cmp esi, edi
jb 0x5077e0
jmp 0x507829
xor esi, esi
nop dword [eax + eax]
mov ecx, dword [ebp + esi*4]
lea edx, [edx + 2]
mov eax, ecx
inc esi
shr eax, 9
shr ecx, 1
mov byte [edx - 2], al
mov byte [edx - 1], cl
cmp esi, edi
jb 0x507810
mov ebp, dword [esp + 0x20]
mov esi, dword [esp + 0x80]
push esi
push ebx
call fcn.00504340
mov ecx, dword [esp + 0x98]
mov edi, dword [esp + 0xac]
push edi
push esi
mov dword [ecx], eax
lea eax, [esp + 0x74]
push ebx
push eax
push dword [esp + 0xb0]
lea eax, [esp + 0x84]
push eax
call fcn.0050c170
add esp, 0x20
test eax, eax
je 0x507883
cmp dword [esp + 0x38], 0
mov esi, dword [esp + 0x30]
jne 0x507898
mov dword [esp + 0x38], 8
jmp 0x507898
mov eax, dword [esp + 0x68]
mov esi, dword [esp + 0x64]
mov dword [esp + 0x34], eax
jmp 0x507898
mov edi, dword [esp + 0xa4]
mov eax, edi
push ebx
push eax
call fcn.004bb3b0
xor ebx, ebx
add esp, 8
xor edi, edi
cmp dword [esp + 0x38], ebx
jne 0x5076ec
mov eax, dword [esp + 0xa0]
mov ebx, dword [esp + 0xa4]
push ebp
push ebx
mov ecx, dword [eax + 0x10]
mov eax, esi
sub eax, dword [ecx + 0x1c]
mov dword [ecx + 8], eax
mov ecx, dword [esp + 0x9c]
mov eax, dword [esp + 0x3c]
mov dword [ecx], eax
mov eax, dword [esp + 0xa4]
mov dword [eax], esi
call fcn.004bb3b0
push dword [esp + 0x30]
push ebx
call fcn.004bb3b0
push edi
push ebx
call fcn.004bb3b0
push dword [esp + 0x34]
push ebx
call fcn.004bb3b0
push edi
push ebx
call fcn.004bb3b0
mov eax, dword [esp + 0x40]
add esp, 0x28
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x74
ret