Function at 0x6292e880
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
mov ebx, ecx
sub esp, 0x4c
mov eax, dword [ebx + 0x1064d8]
lea esi, [eax + 1]
lea eax, [ebx + 0x1064c8]
mov dword [ebx + 0x1064d8], esi
mov ecx, eax
mov dword [ebp - 0x34], eax
call method.OpenMPT::CSoundFile::PlayState.TicksOnRow___const
mov edx, eax
mov eax, dword [ebx + 0x753d0]
cmp esi, edx
jb 0x6292efc0
shr eax, 0x13
mov ecx, ebx
and eax, 1
mov dword [esp + 4], eax
lea eax, [ebx + 0x1064c8]
mov dword [esp], eax
call method.OpenMPT::CSoundFile.NextRow_OpenMPT::CSoundFile::PlayState__bool__const
test byte [ebx + 0x753d0], 0x20
mov byte [ebp - 0x35], al
push ecx
push ecx
jne 0x6292ea3e
movzx eax, byte [ebx + 0x76418]
imul eax, eax, 0x2c
add eax, dword [ebx + 0x76408]
movzx esi, word [ebx + 0x106510]
mov ecx, dword [eax]
mov edx, dword [eax + 4]
sub edx, ecx
mov eax, 0xffff
sar edx, 1
cmp esi, edx
jae 0x6292e913
movzx eax, word [ecx + esi*2]
mov edx, dword [ebx + 0x763f8]
mov ecx, dword [ebx + 0x763fc]
sub ecx, edx
mov word [ebx + 0x10650e], ax
sar ecx, 6
cmp ax, cx
jae 0x6292e945
shl eax, 6
add eax, edx
mov edi, dword [eax]
cmp dword [eax + 4], edi
jne 0x6292e945
mov word [ebx + 0x10650e], 0xfffe
mov edx, dword [ebx + 0x763fc]
mov ax, word [ebx + 0x10650e]
sub edx, dword [ebx + 0x763f8]
sar edx, 6
cmp ax, dx
jb 0x6292ea31
movzx ecx, byte [ebx + 0x76418]
imul ecx, ecx, 0x2c
add ecx, dword [ebx + 0x76408]
mov esi, dword [ecx]
mov dword [ebp - 0x2c], esi
mov esi, dword [ecx + 4]
sub esi, dword [ebp - 0x2c]
mov edi, esi
sar edi, 1
inc ax
je 0x6292e9a1
movzx esi, word [ebx + 0x106510]
mov eax, esi
cmp esi, edi
jae 0x6292e9a1
inc eax
mov word [ebx + 0x106510], ax
jmp 0x6292e8e6
mov ax, word [ecx + 0x28]
test ax, ax
jne 0x6292e9dc
mov esi, dword [ebx + 0x106510]
test si, si
je 0x6292e9dc
movzx edx, si
cmp edx, edi
ja 0x6292e9dc
lea eax, [esi - 1]
movzx esi, ax
add esi, esi
add esi, dword [ebp - 0x2c]
test ax, ax
je 0x6292e9dc
sub esi, 2
cmp word [esi + 2], 0xffff
jne 0x6292e9d9
inc eax
jmp 0x6292e9dc
dec eax
jmp 0x6292e9c7
and dword [ebx + 0x753d0], 0xfff7ffff
mov word [ebx + 0x106510], ax
movzx esi, word [ebx + 0x106510]
mov eax, esi
cmp esi, edi
jae 0x6292ea1f
mov edx, dword [ebp - 0x2c]
cmp word [edx + esi*2], 0xfffe
jne 0x6292ea0e
inc eax
mov word [ebx + 0x106510], ax
jmp 0x6292e9ed
mov dword [esp], esi
call method.OpenMPT::ModSequence.IsValidPat_unsigned_short__const
test al, al
push edx
jne 0x6292e8e6
lea ecx, [ebx + 0x13cf70]
mov dword [esp], 1
jmp 0x6292ebee
mov eax, dword [ebx + 0x106510]
mov word [ebx + 0x106512], ax
movzx esi, word [ebx + 0x10650e]
lea eax, [ebx + 0x763f8]
mov dword [esp], esi
mov ecx, eax
mov dword [ebp - 0x3c], eax
call method.OpenMPT::CPatternContainer.IsValidPat_unsigned_short__const
test al, al
push edx
je 0x6292efb9
shl esi, 6
add esi, dword [ebx + 0x763f8]
mov eax, dword [esi + 0xc]
cmp dword [ebx + 0x1064f8], eax
jb 0x6292ea7f
mov dword [ebx + 0x1064f8], 0
cmp dword [ebx + 0x75410], 0xffffffff
je 0x6292ea95
test byte [ebx + 0x753d0], 0x20
jne 0x6292ed10
lea eax, [ebx + 0x13cf70]
lea esi, [ebx + 0x106730]
mov dword [ebp - 0x2c], eax
lea ecx, [ebx + 0x13cf70]
movzx eax, byte [ebp - 0x35]
mov dword [ebp - 0x30], eax
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x20]
mov dword [ebp - 0x20], esi
mov dword [esp + 8], eax
mov eax, dword [ebx + 0x1064f8]
mov dword [esp + 4], eax
mov dword [ebp - 0x1c], 0x100
movzx eax, word [ebx + 0x106510]
mov dword [esp], eax
call method.OpenMPT::RowVisitor.Visit_unsigned_short__unsigned_int__mpt::mpt_libopenmpt::span_OpenMPT::ModChannel_const__const__bool_
sub esp, 0x10
test al, al
je 0x6292ed10
mov eax, dword [ebx + 0x75410]
test eax, eax
je 0x6292eb4f
jle 0x6292eafd
dec eax
mov dword [ebx + 0x75410], eax
lea ecx, [ebx + 0x13cf70]
mov dword [esp], 1
call method.OpenMPT::RowVisitor.Initialize_bool_
lea ecx, [ebx + 0x13cf70]
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], 0x100
push eax
mov eax, dword [ebp - 0x30]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x20]
mov dword [esp + 8], eax
mov eax, dword [ebx + 0x1064f8]
mov dword [esp + 4], eax
movzx eax, word [ebx + 0x106510]
mov dword [esp], eax
call method.OpenMPT::RowVisitor.Visit_unsigned_short__unsigned_int__mpt::mpt_libopenmpt::span_OpenMPT::ModChannel_const__const__bool_
sub esp, 0x10
jmp 0x6292ed10
test byte [ebx + 0x753d2], 0x40
je 0x6292ebe4
lea eax, [ebx + 0x1064f8]
mov dword [esp + 8], 1
mov dword [esp + 4], eax
lea eax, [ebx + 0x106510]
mov dword [esp], eax
lea ecx, [ebx + 0x13cf70]
call method.OpenMPT::RowVisitor.GetFirstUnvisitedRow_unsigned_short__unsigned_int__bool__const
sub esp, 0xc
test al, al
jne 0x6292ec19
mov eax, dword [ebx + 0x7640c]
mov dword [ebx + 0x106510], 0
sub eax, dword [ebx + 0x76408]
mov dword [ebx + 0x1064f8], 0
sar eax, 2
mov dword [ebx + 0x1064fc], 0
imul eax, eax, 0xba2e8ba3
movzx edi, byte [ebx + 0x76418]
movzx eax, al
dec eax
mov edx, edi
lea ecx, [ebx + 0x76408]
cmp edi, eax
jl 0x6292ebf9
mov dword [esp], 0
call method.OpenMPT::ModSequenceSet.SetSequence_unsigned_char_
push eax
mov dword [esp], 1
mov ecx, dword [ebp - 0x2c]
call method.OpenMPT::RowVisitor.Initialize_bool_
push eax
jmp 0x6292efb9
inc edx
movzx edx, dl
mov dword [esp], edx
call method.OpenMPT::ModSequenceSet.SetSequence_unsigned_char_
lea ecx, [ebx + 0x13cf70]
push edi
mov dword [esp], 1
call method.OpenMPT::RowVisitor.Initialize_bool_
push eax
call method.OpenMPT::CSoundFile.GetChannelMuteFlag__
xor edi, edi
lea edx, [ebx + 0x106730]
mov dword [esp + 0xc], eax
mov dword [esp + 8], edi
mov ecx, edx
mov dword [esp + 4], ebx
mov dword [esp], 7
mov dword [ebp - 0x44], eax
mov dword [ebp - 0x40], edx
call method.OpenMPT::ModChannel.Reset_OpenMPT::ModChannel::ResetFlags__OpenMPT::CSoundFile_const__unsigned_short__OpenMPT::ChannelFlags_
inc edi
mov edx, dword [ebp - 0x40]
sub esp, 0x10
add edx, 0x368
mov eax, dword [ebp - 0x44]
cmp edi, 0x100
jne 0x6292ec26
mov ecx, ebx
call method.OpenMPT::CSoundFile.StopAllVsti__
mov eax, dword [ebx + 0x753c4]
movzx edx, byte [ebx + 0x76418]
imul edx, edx, 0x2c
add edx, dword [ebx + 0x76408]
mov dword [ebx + 0x1064f0], eax
mov eax, dword [ebx + 0x753cc]
mov ecx, dword [ebx + 0x1064f8]
mov edi, dword [edx]
mov dword [ebx + 0x1064f4], eax
mov edx, dword [edx + 4]
mov eax, dword [ebx + 0x753c8]
sub edx, edi
mov dword [ebx + 0x106518], eax
movzx eax, word [ebx + 0x106510]
sar edx, 1
mov word [ebx + 0x106512], ax
mov dword [ebx + 0x1064fc], ecx
cmp eax, edx
jae 0x6292eccb
mov dx, word [edi + eax*2]
mov word [ebx + 0x10650e], dx
lea edx, [ebp - 0x20]
mov edi, dword [ebp - 0x30]
mov dword [esp + 8], edx
mov dword [esp + 4], ecx
mov dword [esp + 0xc], edi
mov ecx, dword [ebp - 0x2c]
mov dword [esp], eax
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x1c], 0x100
call method.OpenMPT::RowVisitor.Visit_unsigned_short__unsigned_int__mpt::mpt_libopenmpt::span_OpenMPT::ModChannel_const__const__bool_
movzx eax, word [ebx + 0x10650e]
sub esp, 0x10
mov ecx, dword [ebp - 0x3c]
mov dword [esp], eax
call method.OpenMPT::CPatternContainer.IsValidPat_unsigned_short__const
test al, al
push esi
je 0x6292efb9
mov eax, dword [ebx + 0x753d0]
mov ecx, ebx
shr eax, 5
and eax, 1
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x34]
mov dword [esp], eax
call method.OpenMPT::CSoundFile.SetupNextRow_OpenMPT::CSoundFile::PlayState__bool__const
mov edi, dword [ebx + 0x1064f8]
movzx edx, word [ebx + 0x10650e]
shl edx, 6
push ecx
add edx, dword [ebx + 0x763f8]
push ecx
mov ecx, edx
mov dword [ebp - 0x2c], edx
call method.OpenMPT::CPattern.GetNumChannels___const
mov edx, dword [ebp - 0x2c]
movzx esi, ax
imul edi, esi
movzx eax, word [ebx + 0x753bc]
imul esi, edi, 6
imul eax, eax, 0x368
lea edi, [ebx + 0x106730]
add esi, dword [edx]
add eax, edi
mov dword [ebp - 0x30], eax
cmp edi, dword [ebp - 0x30]
je 0x6292ef9b
lea eax, [ebx + 0x106490]
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], 0x12
call method.std::bitset_122u_::reference.operator_bool___const
test al, al
je 0x6292eddf
cmp byte [edi + 0x325], 1
jne 0x6292eddf
mov al, byte [esi + 3]
sub eax, 2
cmp al, 1
ja 0x6292eddf
mov eax, dword [edi + 0x2c0]
mov ecx, ebx
mov dword [esp + 8], eax
movsx eax, word [edi + 0x304]
mov dword [esp + 4], eax
movzx eax, byte [edi + 0x320]
mov dword [esp], eax
call method.OpenMPT::CSoundFile.GetPeriodFromNote_unsigned_int__int__unsigned_int__const
sub esp, 0xc
mov dword [edi + 0x2bc], eax
lea eax, [ebx + 0x106490]
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], 0x1b
call method.std::bitset_122u_::reference.operator_bool___const
test al, al
je 0x6292ee66
mov ecx, esi
call method.OpenMPT::ModCommand.IsNote___const
test al, al
jne 0x6292ee66
lea ecx, [edi + 0x314]
call method.OpenMPT::ModCommand.IsNote___const
test al, al
je 0x6292ee66
cmp byte [edi + 0x317], 0x13
jne 0x6292ee66
mov al, byte [edi + 0x319]
mov cl, al
and ecx, 0xfffffff0
cmp cl, 0xd0
jne 0x6292ee66
and eax, 0xf
cmp eax, dword [ebx + 0x1064f0]
jb 0x6292ee66
mov dword [esp + 8], 0
mov ecx, ebx
movsx eax, word [edi + 0x304]
mov dword [esp + 4], eax
movzx eax, byte [edi + 0x314]
mov dword [esp], eax
call method.OpenMPT::CSoundFile.GetPeriodFromNote_unsigned_int__int__unsigned_int__const
sub esp, 0xc
mov dword [edi + 0x2bc], eax
lea eax, [ebx + 0x106494]
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], 0x16
call method.std::bitset_122u_::reference.operator_bool___const
test al, al
je 0x6292eec7
mov ecx, esi
call method.OpenMPT::ModCommand.IsNote___const
test al, al
jne 0x6292eec7
test byte [edi + 0x59], 2
je 0x6292eec7
mov eax, dword [edi + 0x2c4]
mov dword [ebp - 0x2c], eax
test eax, eax
je 0x6292eec7
lea ecx, [edi + 0x314]
mov dword [ebp - 0x3c], ecx
call method.OpenMPT::ModCommand.IsNote___const
test al, al
je 0x6292eec7
mov ecx, dword [ebp - 0x3c]
call method.OpenMPT::ModCommand.IsPortamento___const
test al, al
je 0x6292eec7
mov eax, dword [ebp - 0x2c]
mov dword [edi + 0x2bc], eax
lea eax, [ebx + 0x106490]
lea ecx, [ebp - 0x28]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], 0x1c
call method.std::bitset_122u_::reference.operator_bool___const
lea edx, [ebx + 0x106488]
test al, al
je 0x6292ef33
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x1c], 5
call method.std::bitset_122u_::reference.operator_bool___const
mov edx, dword [ebp - 0x2c]
test al, al
jne 0x6292ef33
cmp dword [ebx + 0x1064f0], 1
jne 0x6292ef33
cmp byte [edi + 0x317], 0x11
jne 0x6292ef33
movzx eax, byte [edi + 0x319]
test al, al
jne 0x6292ef27
mov eax, 1
imul eax, eax, 0x2710
mov dword [ebx + 0x1064f4], eax
mov eax, dword [esi]
lea ecx, [ebp - 0x20]
mov dword [edi + 0x314], eax
mov ax, word [esi + 4]
mov dword [ebp - 0x20], edx
and dword [edi + 0x58], 0xfff9ffff
mov word [edi + 0x318], ax
mov eax, dword [edi + 0x2a4]
mov dword [edi + 0x18], eax
mov eax, dword [edi + 0x2a0]
mov dword [edi + 0x14], eax
mov dword [ebp - 0x1c], 0x15
call method.std::bitset_122u_::reference.operator_bool___const
test al, al
jne 0x6292ef7c
mov byte [edi + 0x33f], 0
mov byte [edi + 0x325], 0
mov dword [edi + 0x35c], 0
add esi, 6
add edi, 0x368
jmp 0x6292ed75
mov ecx, ebx
call method.OpenMPT::CSoundFile.UpdateTimeSignature__
cmp byte [ebp - 0x35], 0
je 0x6292efc0
mov eax, dword [ebx + 0x1064f0]
mov dword [ebx + 0x1064d8], eax
jmp 0x6292e88b
xor eax, eax
jmp 0x6292f04d
cmp dword [ebx + 0x1064f0], 0
jne 0x6292efd3
mov dword [ebx + 0x1064f0], 1
mov edi, dword [ebx + 0x1064d8]
mov eax, dword [ebx + 0x753d0]
test edi, edi
je 0x6292f038
mov esi, eax
mov edx, dword [ebx + 0x753b4]
and esi, 0xffffefff
mov dword [ebx + 0x753d0], esi
test edx, 0x100004
jne 0x6292f046
dec edx
jne 0x6292f008
bt eax, 0x15
jae 0x6292f046
mov ecx, dword [ebp - 0x34]
call method.OpenMPT::CSoundFile::PlayState.TicksOnRow___const
cmp edi, eax
jae 0x6292f046
mov ecx, dword [ebx + 0x1064e0]
xor edx, edx
add ecx, dword [ebx + 0x1064f0]
mov eax, edi
div ecx
test edx, edx
jne 0x6292f046
or esi, 0x1000
mov dword [ebx + 0x753d0], esi
jmp 0x6292f046
and eax, 0xfff7ffff
or ah, 0x10
mov dword [ebx + 0x753d0], eax
mov ecx, ebx
call method.OpenMPT::CSoundFile.ProcessEffects__
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret