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

Disassembly:
sub esp, 0x8c
push ebx
push esi
mov esi, dword [esp + 0xa0]
push edi
mov edi, dword [esp + 0x9c]
mov ebx, dword [edi + 8]
xor edx, edx
mov dword [esp + 0x28], esi
mov dword [esp + 0x14], edx
mov dword [esp + 0x18], edx
mov dword [esp + 0x1c], edx
cmp ebx, edx
jne 0x516a7c
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x8c
ret
push ebp
mov ebp, dword [esp + 0xa4]
mov ecx, 0x6e
cmp ebp, edx
je 0x516a91
movzx ecx, byte [ebp]
lea eax, [ecx - 0x13]
mov dword [esp + 0x10], ecx
cmp eax, 0x96
ja case.0x516aaa.21
movzx eax, byte [eax + 0x5177fc]
jmp dword [eax*4 + 0x517784]
mov ebp, dword [ebp + 0xc]
jmp 0x516a84
movsx ecx, word [ebp + 0x22]
mov eax, dword [ebp + 0x28]
cmp byte [eax], 0
mov edx, dword [eax + 0x1c]
lea ecx, [ecx + ecx*2]
lea ecx, [edx + ecx*8]
jne 0x516ad9
mov eax, dword [ecx + 0x10]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
cmp byte [eax + 1], 0
je 0x516b00
mov ecx, dword [ecx + 0xc]
mov edx, dword [eax + 8]
push esi
push ecx
push edx
push 0x5a
push ebx
call fcn.004c5720
add esp, 0x14
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
xor edx, edx
test byte [ebp + 4], 8
mov ecx, dword [ebp + 0x1c]
je 0x516b7b
mov eax, dword [ebp + 0xc]
push esi
push eax
push edi
call fcn.00516a40
mov ecx, dword [ebp + 0x2c]
mov edi, eax
movsx eax, word [ebp + 0x20]
add esp, 0xc
mov dword [esp + 0x1c], edi
call fcn.004b60a0
movsx ebp, al
cmp ebp, 0x41
je 0x516b6e
cmp edi, esi
je 0x516b4a
push 0
push esi
push edi
push 0x4f
push ebx
call fcn.004c5720
add esp, 0x14
mov dword [esp + 0x1c], esi
mov edx, dword [esp + 0x1c]
push 0xffffffffffffffff
lea ecx, [ebp*2 + 0x5ebce0]
push ecx
push edx
xor eax, eax
push 0x5b
lea ecx, [eax + 1]
mov edi, ebx
call fcn.004c5810
mov edi, dword [esp + 0x2c]
add esp, 0x10
pop ebp
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
cmp ecx, edx
jge 0x516b9a
mov edi, dword [edi + 0x38]
cmp edi, edx
jge 0x516b97
movsx eax, word [ebp + 0x20]
pop ebp
sub eax, edi
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
lea ecx, [edi - 1]
movzx eax, byte [ebp + 0x26]
movsx edx, word [ebp + 0x20]
push eax
mov eax, dword [ebp + 0x2c]
push edx
push eax
mov eax, dword [esp + 0xac]
mov edi, esi
call fcn.004ee830
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
push esi
push 0
push edi
mov eax, ebp
call fcn.004d69c0
add esp, 0xc
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
mov ecx, dword [ebp + 8]
xor edx, edx
cmp byte [ecx + 4], dl
push 0
sete dl
push esi
push edx
push 0x46
push ebx
call fcn.004c5720
add esp, 0x14
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
mov edx, dword [ebp + 8]
mov edi, esi
push edi
push 0
mov esi, ebx
call fcn.004c73d0
add esp, 8
pop ebp
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 8]
mov edi, esi
push eax
mov eax, edi
mov esi, ebx
call fcn.004cbdf0
add esp, 4
pop ebp
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
push 0
push esi
push 0
push 0x49
push ebx
call fcn.004c5720
add esp, 0x14
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
mov edi, dword [ebp + 8]
add edi, 2
mov eax, edi
call fcn.004ad060
mov ebp, eax
mov eax, dword [ebx]
dec ebp
push ebp
push eax
call fcn.004bc6b0
push 0xfffffffffffffff9
push eax
mov eax, ebp
cdq
sub eax, edx
sar eax, 1
push eax
push 0x4b
xor eax, eax
mov ecx, esi
mov edi, ebx
call fcn.004c5810
add esp, 0x18
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
movsx ecx, word [ebp + 0x20]
push 0
push esi
push ecx
push 0x4c
push ebx
call fcn.004c5720
mov edx, dword [ebp + 8]
add esp, 0x14
cmp byte [edx + 1], 0
je 0x516ce8
movsx esi, word [ebp + 0x20]
mov eax, edi
mov ecx, dword [eax + 0xd4]
call fcn.004ae040
push 0xffffffffffffffff
mov edx, ebx
mov dword [ecx], 0
call fcn.004c0210
mov esi, dword [esp + 0xac]
add esp, 4
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 0x1c]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov ecx, dword [ebp + 0xc]
push esi
push ecx
push edi
call fcn.00516a40
add esp, 0xc
mov dword [esp + 0x2c], eax
cmp eax, esi
je 0x516d2c
push 0
push esi
push eax
push 0x4f
push ebx
call fcn.004c5720
add esp, 0x14
mov dword [esp + 0x2c], esi
mov edx, dword [ebp + 8]
xor edi, edi
call fcn.004c21d0
movsx eax, al
push edi
push eax
push esi
push 0x55
push ebx
call fcn.004c5720
mov eax, dword [esp + 0x40]
add esp, 0x14
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
xor edx, edx
cmp ecx, 0x2d
sete dl
mov dword [esp + 0x20], 0x80
add edx, 0x34
mov dword [esp + 0x10], edx
mov ebx, dword [ebp + 0xc]
mov ecx, ebx
call fcn.004c1580
test eax, eax
je 0x516da0
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x10]
push eax
push ecx
push esi
push edi
mov eax, ebp
call fcn.00512bb0
mov eax, dword [esp + 0x3c]
add esp, 0x10
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
lea edx, [esp + 0x18]
push edx
mov eax, ebx
mov esi, edi
call fcn.004ee930
mov edi, eax
lea eax, [esp + 0x20]
push eax
mov eax, dword [ebp + 0x10]
call fcn.004ee930
mov ecx, dword [esp + 0x28]
mov edx, dword [esp + 0x18]
or ecx, 0x20
push ecx
mov ecx, dword [esp + 0xb4]
push ecx
push eax
mov eax, dword [ebp + 0x10]
push edi
push edx
push esi
mov ecx, ebx
call fcn.004ee390
add esp, 0x20
jmp 0x516e1a
lea eax, [esp + 0x18]
push eax
mov eax, dword [ebp + 0xc]
mov esi, edi
call fcn.004ee930
lea ecx, [esp + 0x20]
mov edi, eax
mov eax, dword [ebp + 0x10]
push ecx
call fcn.004ee930
mov edx, dword [esp + 0xb0]
push edx
push edi
push eax
mov eax, dword [esp + 0x24]
push eax
push ebx
call fcn.004c5720
add esp, 0x1c
mov ecx, dword [esp + 0x18]
test ecx, ecx
je 0x516e36
mov al, byte [esi + 0x13]
cmp al, 8
jae 0x516e36
movzx eax, al
mov dword [esi + eax*4 + 0x90], ecx
inc byte [esi + 0x13]
mov ecx, dword [esp + 0x1c]
test ecx, ecx
je 0x516e52
mov al, byte [esi + 0x13]
cmp al, 8
jae 0x516e52
movzx edx, al
mov dword [esi + edx*4 + 0x90], ecx
inc byte [esi + 0x13]
mov eax, dword [esp + 0x2c]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 0xc]
mov cl, byte [eax]
cmp cl, 0x8f
jne 0x516e84
push esi
push 1
push edi
call fcn.004d69c0
add esp, 0xc
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
cmp cl, 0x8d
jne 0x516ea8
mov edx, dword [eax + 8]
mov edi, esi
push edi
push 1
mov esi, ebx
call fcn.004c73d0
add esp, 8
pop ebp
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
lea ecx, [esp + 0x18]
push ecx
lea eax, [esp + 0x38]
mov esi, edi
mov byte [esp + 0x38], 0x8f
mov dword [esp + 0x3c], 0x4400
mov dword [esp + 0x40], edx
call fcn.004ee930
lea edx, [esp + 0x20]
mov edi, eax
mov eax, dword [ebp + 0xc]
push edx
call fcn.004ee930
mov ecx, dword [esp + 0xb0]
push ecx
push edi
push eax
push 0x61
jmp 0x516e11
mov eax, dword [ebp + 0xc]
lea edx, [esp + 0x18]
push edx
mov esi, edi
call fcn.004ee930
mov ecx, eax
mov eax, dword [esp + 0x14]
push eax
mov eax, dword [esp + 0xb0]
push ebx
call fcn.004c57d0
add esp, 0xc
jmp 0x516e1a
mov eax, dword [ebp + 0xc]
lea ecx, [esp + 0x18]
push ecx
mov esi, edi
call fcn.004ee930
mov edx, dword [ebp + 0x10]
mov esi, eax
mov eax, dword [edx + 8]
xor ecx, ecx
cmp byte [eax + 4], cl
sete cl
xor edx, edx
cmp byte [ebp + 0x26], 0x2d
sete dl
xor eax, eax
xor edx, ecx
test ecx, ecx
mov ecx, dword [esp + 0xac]
push edx
sete al
push esi
push 0x58
mov esi, ebx
call fcn.004c5950
add esp, 0x10
mov esi, edi
jmp 0x516e1a
push 0
mov edi, esi
push edi
push 1
push 0x46
push ebx
call fcn.004c5720
mov esi, dword [esp + 0xb4]
lea eax, [esp + 0x2c]
push eax
mov eax, dword [ebp + 0xc]
call fcn.004ee930
mov ecx, dword [esp + 0x28]
push 0
push 0
push eax
push ecx
push ebx
call fcn.004c5720
push 0
push edi
push 0
push 0x46
push ebx
mov esi, eax
call fcn.004c5720
add esp, 0x40
mov eax, esi
mov edx, ebx
call fcn.004bff30
mov esi, dword [esp + 0xa0]
jmp 0x516e1a
mov eax, dword [ebp + 0x28]
cmp eax, edx
jne 0x516fe4
mov edx, dword [ebp + 8]
push edx
push str.misuse_of_aggregate:__s__
mov esi, edi
call fcn.004d3500
mov eax, dword [esp + 0x34]
add esp, 8
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
movsx ecx, word [ebp + 0x22]
mov edx, dword [eax + 0x28]
pop ebp
pop edi
shl ecx, 4
mov eax, dword [ecx + edx + 8]
pop esi
pop ebx
add esp, 0x8c
ret
test dword [ebp + 4], 0x6000
mov eax, dword [edi]
mov dword [esp + 0x1c], eax
mov al, byte [eax + 0x46]
mov dword [esp + 0x20], edx
mov byte [esp + 0x14], al
mov dword [esp + 0x30], edx
jne 0x517030
mov eax, dword [ebp + 0x30]
cmp eax, edx
je 0x517030
mov eax, dword [eax + 0x2c]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
cmp byte [edi + 0x17], dl
je 0x517059
mov eax, ebp
call fcn.004c1960
test eax, eax
je 0x517057
push 0xffffffffffffffff
push ebp
push edi
call fcn.004ee870
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
xor edx, edx
test dword [ebp + 4], 0x4000
je 0x517122
mov dword [esp + 0x18], edx
mov dword [esp + 0x10], edx
mov edx, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
mov eax, dword [ebp + 8]
push 0
push edx
mov edx, dword [esp + 0x24]
push ecx
push edx
mov dword [esp + 0x34], eax
call fcn.004ccf20
add esp, 0x10
mov dword [esp + 0x28], eax
test eax, eax
je 0x51733d
cmp dword [eax + 0x14], 0
jne 0x51733d
mov eax, dword [eax + 4]
test eax, 0x200
je 0x51713c
mov eax, ebx
call fcn.004c59c0
mov ebp, dword [esp + 0x18]
mov dword [esp + 0x24], eax
mov eax, dword [ebp + 4]
push esi
push eax
push edi
call fcn.005178a0
mov eax, dword [esp + 0x1c]
add esp, 0xc
cmp eax, 1
jle 0x517108
add ebp, 0x1c
dec eax
mov dword [esp + 0x14], eax
mov ecx, dword [esp + 0x24]
push 0
push ecx
push esi
push 0x33
push ebx
call fcn.004c5720
mov edx, dword [ebp]
push esi
push edx
push edi
call fcn.005178a0
add esp, 0x20
add ebp, 0x18
sub dword [esp + 0x14], 1
jne 0x5170e0
mov edx, dword [esp + 0x24]
mov ecx, ebx
call fcn.004b3900
mov eax, dword [esp + 0x2c]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 0x14]
mov dword [esp + 0x18], eax
cmp eax, edx
je 0x51706a
mov ecx, dword [eax]
mov dword [esp + 0x10], ecx
jmp 0x51706e
test eax, 0x400
je 0x517160
mov eax, dword [esp + 0x18]
mov ecx, dword [eax + 4]
push esi
push ecx
push edi
call fcn.00516a40
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov ecx, dword [esp + 0x10]
mov dword [esp + 0x24], 0
mov dword [esp + 0x14], 1
test ecx, ecx
jle 0x5171e9
mov edx, dword [esp + 0x18]
add edx, 4
mov dword [esp + 0x2c], edx
cmp dword [esp + 0x24], 0x20
jge 0x5171a5
mov eax, dword [esp + 0x2c]
mov eax, dword [eax]
call fcn.004c1910
test eax, eax
je 0x5171a1
mov ecx, dword [esp + 0x14]
or dword [esp + 0x20], ecx
mov ecx, dword [esp + 0x10]
mov edx, dword [esp + 0x28]
test byte [edx + 4], 0x20
je 0x5171cd
cmp dword [esp + 0x30], 0
jne 0x5171cd
mov eax, dword [esp + 0x2c]
mov eax, dword [eax]
push edi
call fcn.004ee180
mov ecx, dword [esp + 0x14]
add esp, 4
mov dword [esp + 0x30], eax
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x14]
add dword [esp + 0x2c], 0x18
inc eax
rol edx, 1
cmp eax, ecx
mov dword [esp + 0x24], eax
mov dword [esp + 0x14], edx
jl 0x517183
cmp dword [esp + 0x18], 0
je 0x51725a
cmp dword [esp + 0x20], 0
je 0x517204
mov edx, dword [edi + 0x2c]
lea eax, [edx + 1]
add edx, ecx
mov dword [edi + 0x2c], edx
jmp 0x517214
mov esi, ecx
mov ecx, edi
call fcn.004b6a90
mov esi, dword [esp + 0xa8]
mov ecx, dword [esp + 0x28]
test byte [ecx + 4], 0xc0
mov dword [esp + 0x14], eax
je 0x517242
mov edx, dword [esp + 0x18]
mov ecx, dword [edx + 4]
mov dl, byte [ecx]
cmp dl, 0x9e
je 0x517235
cmp dl, 0xa0
jne 0x517242
mov edx, dword [esp + 0x28]
mov dl, byte [edx + 4]
and dl, 0xc0
mov byte [ecx + 0x26], dl
push 3
push 0
push eax
mov eax, dword [esp + 0x24]
push edi
call fcn.004eea60
mov ecx, dword [esp + 0x20]
add esp, 0x10
jmp 0x517262
mov dword [esp + 0x14], 0
cmp ecx, 2
jl 0x51727c
test byte [ebp + 4], 0x80
je 0x51727c
mov eax, dword [esp + 0x28]
push ecx
mov ecx, dword [esp + 0x1c]
push eax
mov eax, dword [ecx + 0x1c]
jmp 0x51728d
test ecx, ecx
jle 0x51729d
mov edx, dword [esp + 0x28]
mov eax, dword [esp + 0x18]
mov eax, dword [eax + 4]
push ecx
push edx
mov ecx, dword [esp + 0x24]
call fcn.004cdae0
mov dword [esp + 0x30], eax
add esp, 8
mov ecx, dword [esp + 0x28]
test byte [ecx + 4], 0x20
je 0x5172d2
cmp dword [esp + 0x30], 0
jne 0x5172b9
mov edx, dword [esp + 0x1c]
mov eax, dword [edx + 8]
mov dword [esp + 0x30], eax
mov ecx, dword [esp + 0x30]
push 0xfffffffffffffffe
push ecx
push 0
push 0x52
xor eax, eax
xor ecx, ecx
mov edi, ebx
call fcn.004c5810
add esp, 0x10
mov edx, dword [esp + 0x28]
mov ecx, dword [esp + 0xa0]
mov eax, dword [esp + 0x20]
mov ebp, dword [esp + 0x14]
push 0xfffffffffffffff8
push edx
mov edx, dword [ecx + 0x38]
neg edx
sbb edx, edx
push eax
add edx, 0x3f
push edx
mov eax, esi
mov ecx, ebp
mov edi, ebx
call fcn.004c5810
movzx dx, byte [esp + 0x20]
add esp, 0x10
mov ecx, ebx
call fcn.004b3950
mov ecx, dword [esp + 0x10]
test ecx, ecx
je 0x517330
cmp dword [esp + 0x20], 0
jne 0x517330
mov eax, dword [esp + 0xa0]
push eax
mov edx, ebp
call fcn.004b6ae0
add esp, 4
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
mov ecx, dword [esp + 0x24]
push ecx
push str.unknown_function:__s__
mov esi, edi
call fcn.004d3500
mov eax, dword [esp + 0x34]
add esp, 8
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
cmp ecx, 0x7f
jne 0x517392
mov edx, dword [ebp + 0x14]
mov eax, dword [edx]
mov eax, dword [eax]
cmp eax, 1
je 0x517392
push 1
push eax
push str.sub_select_returns__d_columns___expected__d
mov esi, edi
call fcn.004d3500
mov eax, dword [esp + 0x38]
add esp, 0xc
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
push 0
push 0
push ebp
push edi
call fcn.0050ff90
add esp, 0x10
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 0xc]
cmp dword [eax + 0x1c], edx
jne 0x5173c9
push 0
push 0
push eax
push edi
call fcn.0050ff90
mov ecx, dword [ebp + 0xc]
add esp, 0x10
mov dword [ecx + 0x1c], eax
xor edx, edx
mov esi, dword [ebp + 0x1c]
cmp esi, edx
je 0x5173ed
mov ecx, dword [ebp + 0xc]
call fcn.004b60f0
cmp esi, eax
je 0x5173ed
push eax
push esi
push str._d_columns_assigned__d_values
mov esi, edi
call fcn.004d3500
add esp, 0xc
movsx eax, word [ebp + 0x20]
mov edx, dword [ebp + 0xc]
add eax, dword [edx + 0x1c]
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, ebx
call fcn.004c59c0
mov dword [esp + 0x14], eax
mov eax, ebx
call fcn.004c59c0
push 0
push esi
push 0
push 0x49
push ebx
mov dword [esp + 0x38], eax
call fcn.004c5720
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x28]
push eax
push ecx
push ebp
push edi
call fcn.00512fa0
push 0
push esi
push 1
push 0x46
push ebx
call fcn.004c5720
mov edx, dword [esp + 0x4c]
mov ecx, ebx
call fcn.004b3900
push 0
push 0
push esi
push 0x53
push ebx
call fcn.004c5720
mov edx, dword [esp + 0x70]
add esp, 0x4c
mov ecx, ebx
call fcn.004b3900
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
push 0
push 0
push esi
push ebp
push edi
call fcn.005106b0
add esp, 0x14
pop ebp
pop edi
mov eax, esi
pop esi
pop ebx
add esp, 0x8c
ret
mov edi, dword [ebp + 0x2c]
movsx edx, word [edi + 0x2a]
movsx eax, word [ebp + 0x20]
inc edx
imul edx, dword [ebp + 0x1c]
push 0
push esi
lea ecx, [edx + eax + 1]
push ecx
push 0x96
push ebx
call fcn.004c5720
movzx eax, word [ebp + 0x20]
add esp, 0x14
test ax, ax
jl 0x516e52
movsx edx, ax
mov eax, dword [edi + 4]
shl edx, 4
cmp byte [edx + eax + 0xd], 0x45
jne 0x516e52
push 0
push 0
mov ecx, esi
push ecx
push 0x54
push ebx
call fcn.004c5720
mov eax, dword [esp + 0x40]
add esp, 0x14
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
push str.row_value_misused
mov esi, edi
call fcn.004d3500
mov eax, dword [esp + 0x30]
add esp, 4
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 0x1c]
push 0
push 0
push eax
push 0x15
push ebx
call fcn.004c5720
mov edx, dword [ebp + 0xc]
push esi
push edx
push edi
mov dword [esp + 0x34], eax
call fcn.00516a40
mov esi, dword [esp + 0x34]
mov edi, eax
mov eax, esi
mov edx, ebx
mov dword [esp + 0x4c], edi
call fcn.004bff30
push ebx
mov edx, edi
mov eax, esi
call fcn.004bff00
add esp, 0x24
pop ebp
mov eax, edi
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
cmp dword [edi + 0x78], edx
jne 0x517585
push str.RAISE___may_only_be_used_within_a_trigger_program
mov esi, edi
call fcn.004d3500
add esp, 4
pop ebp
pop edi
pop esi
xor eax, eax
pop ebx
add esp, 0x8c
ret
cmp byte [ebp + 1], 2
jne 0x517592
mov ecx, edi
call fcn.004b78f0
mov al, byte [ebp + 1]
push 0
cmp al, 4
jne 0x5175c1
mov eax, dword [ebp + 8]
push eax
xor eax, eax
push 0
push 0x45
lea ecx, [eax + 4]
mov edi, ebx
call fcn.004c5810
mov eax, dword [esp + 0x3c]
add esp, 0x10
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov ecx, dword [ebp + 8]
push 0
movsx edx, al
push ecx
push edx
push 0x713
call fcn.004d0640
mov eax, dword [esp + 0x40]
add esp, 0x14
pop ebp
pop edi
pop esi
pop ebx
add esp, 0x8c
ret
mov eax, dword [ebp + 0x14]
mov dword [esp + 0x10], eax
mov eax, dword [eax]
mov dword [esp + 0x30], eax
mov eax, ebx
mov dword [esp + 0x14], edx
call fcn.004c59c0
mov ebp, dword [ebp + 0xc]
mov dword [esp + 0x28], eax
mov dword [esp + 0x24], ebp
test ebp, ebp
je 0x51767d
mov eax, dword [esp + 0xa0]
mov ecx, 0xd
mov esi, ebp
lea edi, [esp + 0x34]
rep movsd dword es:[edi], dword [esi]
lea ecx, [esp + 0x34]
push ecx
lea edx, [esp + 0x1c]
call fcn.005105e0
mov dl, byte [esp + 0x38]
and dword [esp + 0x3c], 0xffffefff
push 0x34
mov dword [esp + 0x58], eax
lea eax, [esp + 0x70]
push 0
push eax
mov byte [esp + 0x6a], dl
mov byte [esp + 0x44], 0xa4
call fcn.00586030
mov esi, dword [esp + 0xb8]
mov edi, dword [esp + 0xb0]
lea ecx, [esp + 0x44]
lea edx, [esp + 0x78]
add esp, 0x10
mov byte [esp + 0x68], 0x35
mov dword [esp + 0x74], ecx
mov dword [esp + 0x14], edx
mov ecx, dword [esp + 0x30]
lea eax, [ecx - 1]
test eax, eax
jle 0x517722
mov ecx, dword [esp + 0x10]
dec eax
add ecx, 4
shr eax, 1
inc eax
mov dword [esp + 0x20], ecx
mov dword [esp + 0x1c], eax
nop
cmp dword [esp + 0x24], 0
je 0x5176b3
mov eax, dword [esp + 0x20]
mov ecx, dword [eax]
mov dword [esp + 0x78], ecx
jmp 0x5176bd
mov edx, dword [esp + 0x20]
mov eax, dword [edx]
mov dword [esp + 0x14], eax
mov eax, ebx
call fcn.004c59c0
mov ecx, dword [esp + 0x14]
push 0x10
mov ebp, eax
push ebp
push ecx
push edi
call fcn.005142b0
mov edx, dword [esp + 0x30]
mov eax, dword [edx + 0x18]
push esi
push eax
push edi
call fcn.005178a0
mov ecx, dword [esp + 0x44]
push 0
push ecx
push 0
push 0xb
push ebx
call fcn.004c5720
mov eax, dword [ebx + 0xc]
mov eax, dword [eax + 0x40]
add esp, 0x30
test eax, eax
je 0x517712
mov ecx, dword [ebx + 0x88]
lea edx, [ebp*4 + 4]
sub eax, edx
mov dword [eax], ecx
add dword [esp + 0x20], 0x30
sub dword [esp + 0x1c], 1
jne 0x5176a0
mov ecx, dword [esp + 0x30]
test cl, 1
je 0x51773f
mov eax, dword [esp + 0x10]
lea edx, [ecx + ecx*2]
mov ecx, dword [eax + edx*8 - 0x14]
push esi
push ecx
push edi
call fcn.005178a0
add esp, 0xc
jmp 0x51774f
push 0
push esi
push 0
push 0x49
push ebx
call fcn.004c5720
add esp, 0x14
mov eax, dword [ebx + 0xc]
mov eax, dword [eax + 0x40]
test eax, eax
je 0x516e52
mov edx, dword [esp + 0x28]
pop ebp
lea ecx, [edx*4 + 4]
mov edx, dword [ebx + 0x88]
pop edi
sub eax, ecx
pop esi
mov dword [eax], edx
mov eax, dword [esp + 0x20]
pop ebx
add esp, 0x8c
ret