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

Disassembly:
sub esp, 0x468
push ebx
mov ebx, ecx
mov dword [esp + 0x68], edx
push ebp
push esi
push edi
mov eax, dword [ebx + 0x10]
lea edx, [ebx + 0x18]
mov dword [esp + 0x70], ebx
lea ebp, [ebx + 0x14]
mov dword [esp + 0x34], 0
mov dword [esp + 0x2c], 0
mov dword [esp + 0x18], 0
mov dword [esp + 0x40], 0
mov dword [esp + 0x28], 0
mov dword [esp + 0x20], edx
mov dword [esp + 0x44], ebp
test eax, eax
je 0x1004f4e9
push eax
call fcn.100bc447
mov ecx, eax
lea edx, [ebx + 0x18]
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004f503
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004fbf2
movzx ecx, byte [eax]
inc eax
mov dword [ebp], eax
mov dword [esp + 0x20], edx
mov dword [esp + 0x44], ebp
cmp ecx, 0x42
jne 0x1004fbf2
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004f528
push eax
call fcn.100bc447
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004f53a
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004fbf2
movzx ecx, byte [eax]
inc eax
mov dword [ebp], eax
cmp ecx, 0x4d
jne 0x1004fbf2
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edi, eax
mov ecx, ebx
shl edi, 0x10
add edi, esi
mov dword [esp + 0x10], edi
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
shl eax, 0x10
add eax, esi
mov dword [esp + 0x14], eax
cmp eax, 0xc
je 0x1004f5be
cmp eax, 0x28
je 0x1004f5be
cmp eax, 0x38
je 0x1004f5be
cmp eax, 0x6c
je 0x1004f5be
pop edi
pop esi
pop ebp
mov dword [0x101109d0], 0x100eeda8
xor eax, eax
pop ebx
add esp, 0x468
ret
mov dword [0x101109d0], str.bad_BMP
mov ecx, ebx
cmp eax, 0xc
jne 0x1004f5df
call fcn.1004a700
mov ecx, ebx
mov dword [ebx], eax
call fcn.1004a700
jmp 0x1004f609
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
shl eax, 0x10
mov ecx, ebx
add eax, esi
mov dword [ebx], eax
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
shl eax, 0x10
add eax, esi
mov ecx, ebx
mov dword [ebx + 4], eax
call fcn.1004a700
cmp eax, 1
jne 0x1004fbfc
mov ecx, ebx
call fcn.1004a700
mov ecx, eax
mov dword [esp + 0x1c], ecx
cmp ecx, 1
jne 0x1004f645
pop edi
pop esi
pop ebp
mov dword [0x101109d0], 0x100eedd0
xor eax, eax
pop ebx
add esp, 0x468
ret
mov eax, dword [ebx + 4]
mov esi, dword [esp + 0x14]
mov dword [esp + 0x6c], eax
cdq
xor eax, edx
sub eax, edx
mov dword [ebx + 4], eax
cmp esi, 0xc
jne 0x1004f67c
cmp ecx, 0x18
jge 0x1004f8c3
lea ecx, [edi - 0x26]
mov eax, 0x55555556
imul ecx
mov eax, edx
shr eax, 0x1f
add eax, edx
jmp 0x1004f8bf
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edi, eax
shl edi, 0x10
add edi, esi
cmp edi, 1
je 0x1005014c
cmp edi, 2
je 0x1005014c
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov esi, dword [esp + 0x14]
cmp esi, 0x28
je 0x1004f7f0
cmp esi, 0x38
je 0x1004f7b8
cmp esi, 0x6c
je 0x1004f71d
push 0xa18
push str.C:UsersPCDesktopheadcoreHeadCoreincludesSoil_stb_image_aug.cpp
push str.hsz__108
call fcn.100bb717
add esp, 0xc
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edi, eax
mov ecx, ebx
shl edi, 0x10
add edi, esi
mov dword [esp + 0x34], edi
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edi, eax
mov ecx, ebx
shl edi, 0x10
add edi, esi
mov dword [esp + 0x2c], edi
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edi, eax
mov ecx, ebx
shl edi, 0x10
add edi, esi
mov dword [esp + 0x18], edi
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
shl eax, 0x10
mov ecx, ebx
add eax, esi
mov dword [esp + 0x40], eax
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov esi, 0xc
nop word [eax + eax]
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
sub esi, 1
jne 0x1004f7a0
jmp 0x1004f8a6
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
call fcn.1004a700
mov eax, dword [esp + 0x1c]
cmp eax, 0x10
je 0x1004f802
cmp eax, 0x20
jne 0x1004f8ae
test edi, edi
jne 0x1004f83e
cmp eax, 0x20
mov edx, 0x7c00
mov ecx, 0xff0000
cmovne ecx, edx
mov edx, 0x3e0
mov dword [esp + 0x34], ecx
mov ecx, 0xff00
cmovne ecx, edx
mov edx, 0x1f
mov dword [esp + 0x2c], ecx
mov ecx, 0xff
cmovne ecx, edx
mov dword [esp + 0x18], ecx
jmp 0x1004f8ae
cmp edi, 3
jne 0x1004fbfc
mov ecx, ebx
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edi, eax
mov ecx, ebx
shl edi, 0x10
add edi, esi
mov dword [esp + 0x34], edi
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
shl eax, 0x10
mov ecx, ebx
add eax, esi
mov dword [esp + 0x2c], eax
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov ecx, dword [esp + 0x2c]
mov edx, eax
shl edx, 0x10
add edx, esi
mov dword [esp + 0x18], edx
cmp edi, ecx
jne 0x1004f8a6
cmp ecx, edx
je 0x1004fbfc
mov esi, dword [esp + 0x14]
mov eax, dword [esp + 0x1c]
cmp eax, 0x10
jge 0x1004f8c3
mov eax, dword [esp + 0x10]
sub eax, esi
sub eax, 0xe
sar eax, 2
mov dword [esp + 0x28], eax
xor eax, eax
cmp dword [esp + 0x40], eax
setne al
xor ecx, ecx
add eax, 3
mov dword [ebx + 8], eax
mov eax, dword [ebx]
shl eax, 2
mul dword [ebx + 4]
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.100bb798
mov edi, eax
add esp, 4
mov dword [esp + 0x24], edi
test edi, edi
jne 0x1004f90b
pop edi
pop esi
pop ebp
mov dword [0x101109d0], 0x100ee9f4
pop ebx
add esp, 0x468
ret
cmp dword [esp + 0x1c], 0x10
jge 0x1004fc09
mov eax, dword [esp + 0x28]
xor esi, esi
test eax, eax
je 0x1004fbe9
cmp eax, 0x100
jg 0x1004fbe9
mov dword [esp + 0x18], esi
test eax, eax
jle 0x1004fa3d
mov edi, dword [esp + 0x14]
nop
mov eax, dword [ebx + 0x10]
lea esi, [esp + 0x7a]
test eax, eax
je 0x1004f964
push eax
call fcn.100bc447
mov edx, dword [esp + 0x24]
mov ecx, eax
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004f97a
mov edx, dword [esp + 0x20]
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004f978
movzx ecx, byte [eax]
inc eax
mov dword [ebp], eax
jmp 0x1004f97a
xor ecx, ecx
mov eax, dword [esp + 0x18]
mov byte [esi + eax*4], cl
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004f9a1
push eax
call fcn.100bc447
mov edx, dword [esp + 0x24]
mov ecx, eax
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004f9b3
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004f9b1
movzx ecx, byte [eax]
inc eax
mov dword [ebp], eax
jmp 0x1004f9b3
xor ecx, ecx
mov eax, dword [esp + 0x18]
mov byte [esp + eax*4 + 0x79], cl
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004f9db
push eax
call fcn.100bc447
mov edx, dword [esp + 0x24]
mov ecx, eax
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004f9ed
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004f9eb
movzx ecx, byte [eax]
inc eax
mov dword [ebp], eax
jmp 0x1004f9ed
xor ecx, ecx
mov eax, dword [esp + 0x18]
lea esi, [esp + 0x78]
mov byte [esi + eax*4], cl
mov esi, dword [esp + 0x28]
cmp edi, 0xc
je 0x1004fa1e
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fa13
push eax
call fcn.100bc447
add esp, 4
jmp 0x1004fa1e
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004fa1e
inc eax
mov dword [ebp], eax
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x7b]
mov byte [eax + ecx*4], 0xff
inc ecx
mov dword [esp + 0x18], ecx
cmp ecx, esi
jl 0x1004f940
mov edi, dword [esp + 0x24]
xor esi, esi
mov ecx, dword [esp + 0x10]
xor eax, eax
cmp dword [esp + 0x14], 0xc
setne al
add eax, 3
imul eax, dword [esp + 0x28]
sub ecx, eax
mov eax, dword [ebx + 0x10]
sub ecx, dword [esp + 0x14]
sub ecx, 0xe
test eax, eax
je 0x1004fa71
push 1
push ecx
push eax
call fcn.100b033b
add esp, 0xc
jmp 0x1004fa74
add dword [ebp], ecx
mov eax, dword [esp + 0x1c]
cmp eax, 4
jne 0x1004fa84
mov ecx, dword [ebx]
inc ecx
shr ecx, 1
jmp 0x1004fa8f
cmp eax, 8
jne 0x1004fbe9
mov ecx, dword [ebx]
mov edx, dword [ebx + 4]
neg ecx
and ecx, 3
xor edi, edi
mov dword [esp + 0x3c], ecx
mov dword [esp + 0x10], edi
test edx, edx
jle 0x100500a8
nop dword [eax]
cmp dword [ebx], 0
mov dword [esp + 0x30], 0
jle 0x1004fbb8
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fadd
push eax
call fcn.100bc447
mov edi, eax
add esp, 4
xor eax, eax
cmp edi, 0xffffffff
cmove edi, eax
jmp 0x1004faf3
mov ecx, dword [esp + 0x20]
mov eax, dword [ebp]
cmp eax, dword [ecx]
jae 0x1004faf1
movzx edi, byte [eax]
inc eax
mov dword [ebp], eax
jmp 0x1004faf3
xor edi, edi
xor ecx, ecx
mov edx, edi
and edx, 0xf
cmp dword [esp + 0x1c], 4
cmovne edx, ecx
mov ecx, edi
sar ecx, 4
cmp dword [esp + 0x1c], 4
cmovne ecx, edi
mov edi, dword [esp + 0x24]
movzx eax, byte [esp + ecx*4 + 0x78]
mov byte [esi + edi], al
movzx eax, byte [esp + ecx*4 + 0x79]
mov byte [esi + edi + 1], al
movzx eax, byte [esp + ecx*4 + 0x7a]
mov ecx, dword [ebx]
mov byte [esi + edi + 2], al
mov eax, dword [esp + 0x30]
mov byte [esi + edi + 3], 0xff
inc eax
add esi, 4
cmp eax, ecx
je 0x1004fbb0
cmp dword [esp + 0x1c], 8
jne 0x1004fb7b
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fb65
push eax
call fcn.100bc447
mov ecx, dword [ebx]
mov edx, eax
xor eax, eax
add esp, 4
cmp edx, 0xffffffff
cmove edx, eax
jmp 0x1004fb7b
mov edx, dword [esp + 0x20]
mov eax, dword [ebp]
cmp eax, dword [edx]
jae 0x1004fb79
movzx edx, byte [eax]
inc eax
mov dword [ebp], eax
jmp 0x1004fb7b
xor edx, edx
movzx eax, byte [esp + edx*4 + 0x78]
mov byte [esi + edi], al
movzx eax, byte [esp + edx*4 + 0x79]
mov byte [esi + edi + 1], al
movzx eax, byte [esp + edx*4 + 0x7a]
mov edx, dword [esp + 0x30]
mov byte [esi + edi + 2], al
add edx, 2
mov byte [esi + edi + 3], 0xff
add esi, 4
mov dword [esp + 0x30], edx
cmp edx, ecx
jl 0x1004fac1
mov ecx, dword [esp + 0x3c]
mov edi, dword [esp + 0x10]
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fbd1
push 1
push ecx
push eax
call fcn.100b033b
mov ecx, dword [esp + 0x48]
add esp, 0xc
jmp 0x1004fbd4
add dword [ebp], ecx
mov edx, dword [ebx + 4]
inc edi
mov dword [esp + 0x10], edi
cmp edi, edx
jl 0x1004fab0
jmp 0x100500a8
push edi
call fcn.100b61b5
add esp, 4
mov dword [0x101109d0], str.Corrupt_BMP
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x468
ret
mov eax, dword [esp + 0x10]
xor edi, edi
mov ecx, dword [ebx + 0x10]
sub eax, esi
xor edx, edx
mov dword [esp + 0x50], 0
xor ebp, ebp
mov dword [esp + 0x54], 0
sub eax, 0xe
mov dword [esp + 0x30], 0
mov dword [esp + 0x3c], 0
mov dword [esp + 0x48], edi
mov dword [esp + 0x28], edx
test ecx, ecx
je 0x1004fc5b
push 1
push eax
push ecx
call fcn.100b033b
mov esi, dword [esp + 0x50]
add esp, 0xc
xor edx, edx
jmp 0x1004fc61
mov esi, dword [esp + 0x44]
add dword [esi], eax
mov ecx, dword [esp + 0x1c]
cmp ecx, 0x18
jne 0x1004fc82
mov eax, dword [ebx]
and eax, 3
mov dword [esp + 0x28], 1
mov dword [esp + 0x14], eax
xor eax, eax
jmp 0x1004fd8a
cmp ecx, 0x10
jne 0x1004fcba
mov eax, dword [ebx]
add eax, eax
neg eax
and eax, 3
mov edi, dword [esp + 0x34]
mov dword [esp + 0x14], eax
mov dword [esp + 0x28], edx
test edi, edi
je 0x1004fbf2
cmp dword [esp + 0x2c], ebp
je 0x1004fbf2
cmp dword [esp + 0x18], ebp
je 0x1004fbf2
jmp 0x1004fd02
xor eax, eax
mov dword [esp + 0x14], eax
cmp ecx, 0x20
jne 0x1004fc90
cmp dword [esp + 0x18], 0xff
jne 0x1004fc90
cmp dword [esp + 0x2c], 0xff00
jne 0x1004fc90
cmp dword [esp + 0x34], 0xff000000
jne 0x1004fc90
cmp dword [esp + 0x40], 0xff000000
jne 0x1004fcfe
mov dword [esp + 0x28], 2
mov dword [esp + 0x14], eax
jmp 0x1004fd8a
mov edi, dword [esp + 0x34]
mov ecx, edi
call fcn.1004f420
sub eax, 7
mov edx, edi
mov dword [esp + 0x50], eax
and edi, 0x55555555
shr edx, 1
and edx, 0x55555555
add edx, edi
mov eax, edx
and edx, 0x33333333
shr eax, 2
and eax, 0x33333333
add eax, edx
mov ecx, eax
shr ecx, 4
add ecx, eax
and ecx, 0xf0f0f0f
mov eax, ecx
shr eax, 8
add ecx, eax
mov eax, ecx
shr eax, 0x10
add eax, ecx
mov ecx, dword [esp + 0x2c]
movzx edi, al
mov dword [esp + 0x48], edi
call fcn.1004f420
mov ecx, dword [esp + 0x18]
sub eax, 7
mov dword [esp + 0x54], eax
call fcn.1004f420
mov ecx, dword [esp + 0x40]
sub eax, 7
mov dword [esp + 0x30], eax
call fcn.1004f420
mov ecx, dword [esp + 0x1c]
sub eax, 7
mov dword [esp + 0x3c], eax
mov edx, dword [ebx + 4]
mov dword [esp + 0x4c], ebp
test edx, edx
jle 0x100500a8
mov edx, dword [esp + 0x50]
neg edx
mov dword [esp + 0x5c], edx
mov edx, dword [esp + 0x54]
neg edx
mov dword [esp + 0x60], edx
mov edx, dword [esp + 0x30]
neg edx
neg eax
mov dword [esp + 0x64], edx
mov dword [esp + 0x68], eax
nop dword [eax]
cmp dword [esp + 0x28], 0
mov eax, dword [ebx]
je 0x1004fef6
mov dword [esp + 0x10], 0
test eax, eax
jle 0x1005006a
mov ecx, dword [esp + 0x24]
lea eax, [ecx + 2]
mov dword [esp + 0x38], eax
lea eax, [ecx + 1]
mov edi, dword [esp + 0x38]
mov dword [esp + 0x58], eax
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fe13
push eax
call fcn.100bc447
mov edx, dword [esp + 0x24]
mov ecx, eax
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fe27
mov edx, dword [esp + 0x20]
mov eax, dword [esi]
cmp eax, dword [edx]
jae 0x1004fe25
movzx ecx, byte [eax]
inc eax
mov dword [esi], eax
jmp 0x1004fe27
xor ecx, ecx
mov eax, dword [ebx + 0x10]
mov byte [edi + ebp], cl
test eax, eax
je 0x1004fe4a
push eax
call fcn.100bc447
mov edx, dword [esp + 0x24]
mov ecx, eax
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fe5a
mov eax, dword [esi]
cmp eax, dword [edx]
jae 0x1004fe58
movzx ecx, byte [eax]
inc eax
mov dword [esi], eax
jmp 0x1004fe5a
xor ecx, ecx
mov eax, dword [esp + 0x58]
mov byte [eax + ebp], cl
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004fe7d
push eax
call fcn.100bc447
mov ecx, eax
add esp, 4
xor eax, eax
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fe8d
mov eax, dword [esi]
cmp eax, dword [edx]
jae 0x1004fe8b
movzx ecx, byte [eax]
inc eax
mov dword [esi], eax
jmp 0x1004fe8d
xor ecx, ecx
cmp dword [esp + 0x28], 2
mov edx, dword [esp + 0x24]
mov byte [edx + ebp], cl
jne 0x1004fed0
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x1004febb
push eax
call fcn.100bc447
mov edx, dword [esp + 0x28]
mov ecx, eax
xor eax, eax
add esp, 4
cmp ecx, 0xffffffff
cmove ecx, eax
jmp 0x1004fed5
mov ecx, dword [esp + 0x20]
mov eax, dword [esi]
cmp eax, dword [ecx]
jae 0x1004fecc
movzx ecx, byte [eax]
inc dword [esi]
jmp 0x1004fed5
xor ecx, ecx
jmp 0x1004fed5
mov ecx, 0xff
mov byte [edx + ebp + 3], cl
add ebp, 4
mov edx, dword [esp + 0x10]
inc edx
mov dword [esp + 0x10], edx
cmp edx, dword [ebx]
jl 0x1004fdf3
mov edi, dword [esp + 0x48]
jmp 0x1005006a
mov dword [esp + 0x38], 0
test eax, eax
jle 0x1005006a
cmp ecx, 0x10
mov ecx, ebx
jne 0x1004ff16
call fcn.1004a700
mov edx, eax
jmp 0x1004ff2b
call fcn.1004a700
mov ecx, ebx
mov esi, eax
call fcn.1004a700
mov edx, eax
shl edx, 0x10
add edx, esi
mov ecx, dword [esp + 0x50]
mov esi, edx
and esi, dword [esp + 0x34]
mov eax, esi
sar eax, cl
mov ecx, dword [esp + 0x5c]
shl esi, cl
mov ecx, edi
cmp dword [esp + 0x50], 0
cmovge esi, eax
mov eax, esi
mov dword [esp + 0x10], eax
cmp edi, 8
jae 0x1004ff67
mov eax, esi
sar eax, cl
add ecx, edi
add dword [esp + 0x10], eax
cmp ecx, 8
jl 0x1004ff54
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x24]
mov esi, edx
and esi, dword [esp + 0x2c]
mov byte [ecx + ebp], al
mov eax, esi
mov ecx, dword [esp + 0x54]
sar eax, cl
mov ecx, dword [esp + 0x60]
shl esi, cl
mov ecx, edi
cmp dword [esp + 0x54], 0
cmovge esi, eax
mov eax, esi
mov dword [esp + 0x10], eax
cmp edi, 8
jae 0x1004ffaa
mov eax, esi
sar eax, cl
add ecx, edi
add dword [esp + 0x10], eax
cmp ecx, 8
jl 0x1004ff97
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x24]
mov esi, edx
and esi, dword [esp + 0x18]
mov byte [ecx + ebp + 1], al
mov eax, esi
mov ecx, dword [esp + 0x30]
sar eax, cl
mov ecx, dword [esp + 0x64]
shl esi, cl
mov ecx, edi
cmp dword [esp + 0x30], 0
cmovge esi, eax
mov eax, esi
mov dword [esp + 0x10], eax
cmp edi, 8
jae 0x1004fff3
nop dword [eax + eax]
mov eax, esi
sar eax, cl
add ecx, edi
add dword [esp + 0x10], eax
cmp ecx, 8
jl 0x1004ffe0
mov eax, dword [esp + 0x10]
mov esi, dword [esp + 0x24]
mov byte [esi + ebp + 2], al
mov eax, dword [esp + 0x40]
test eax, eax
je 0x10050049
mov ecx, dword [esp + 0x3c]
and edx, eax
mov eax, edx
sar eax, cl
mov ecx, dword [esp + 0x68]
shl edx, cl
mov ecx, edi
cmp dword [esp + 0x3c], 0
cmovge edx, eax
mov eax, edx
mov dword [esp + 0x10], eax
cmp edi, 8
jae 0x1005004e
mov esi, edx
nop word [eax + eax]
mov eax, edx
sar eax, cl
add ecx, edi
add esi, eax
cmp ecx, 8
jl 0x10050030
mov dword [esp + 0x10], esi
mov eax, esi
mov esi, dword [esp + 0x24]
jmp 0x1005004e
mov eax, 0xff
mov ecx, dword [esp + 0x38]
inc ecx
mov byte [esi + ebp + 3], al
add ebp, 4
mov dword [esp + 0x38], ecx
cmp ecx, dword [ebx]
mov ecx, dword [esp + 0x1c]
jl 0x1004ff06
mov eax, dword [ebx + 0x10]
test eax, eax
je 0x10050086
push 1
push dword [esp + 0x18]
push eax
call fcn.100b033b
mov esi, dword [esp + 0x50]
add esp, 0xc
jmp 0x10050090
mov esi, dword [esp + 0x44]
mov eax, dword [esp + 0x14]
add dword [esi], eax
mov eax, dword [esp + 0x4c]
mov edx, dword [ebx + 4]
inc eax
mov ecx, dword [esp + 0x1c]
mov dword [esp + 0x4c], eax
cmp eax, edx
jl 0x1004fdc0
cmp dword [esp + 0x6c], 0
jle 0x10050129
mov edi, edx
sar edi, 1
mov dword [esp + 0x48], edi
test edi, edi
jle 0x10050129
mov eax, dword [ebx]
mov ebp, eax
mov esi, dword [esp + 0x24]
neg ebp
shl ebp, 2
mov dword [esp + 0x4c], ebp
lea ebp, [edx*4 - 4]
imul ebp, eax
lea ebx, [eax*4]
mov eax, dword [esp + 0x4c]
mov dword [esp + 0x38], esi
add ebp, esi
test ebx, ebx
jle 0x10050114
mov edi, esi
mov edx, ebp
sub edi, ebp
mov esi, ebx
mov al, byte [edx]
lea edx, [edx + 1]
mov cl, byte [edx + edi - 1]
mov byte [edx + edi - 1], al
mov byte [edx - 1], cl
sub esi, 1
jne 0x100500f3
mov esi, dword [esp + 0x38]
mov edi, dword [esp + 0x48]
mov eax, dword [esp + 0x4c]
add esi, ebx
add ebp, eax
sub edi, 1
mov dword [esp + 0x38], esi
mov dword [esp + 0x48], edi
jne 0x100500e7
mov ebx, dword [esp + 0x70]
mov ecx, dword [esp + 0x74]
mov eax, dword [ebx]
pop edi
pop esi
mov dword [ecx], eax
mov eax, dword [esp + 0x474]
mov ecx, dword [ebx + 4]
pop ebp
pop ebx
mov dword [eax], ecx
mov eax, dword [esp + 0x14]
add esp, 0x468
ret
pop edi
pop esi
pop ebp
mov dword [0x101109d0], 0x100eedf0
xor eax, eax
pop ebx
add esp, 0x468
ret