system "Double Trouble v2"
{
*************************************
*     System by Mr Troublemaker     *
*          on the VIP Lounge        *
*************************************
          Rx-ed by St0rm0r
-------------------------------------
        00-c0mpatible
-------------------------------------
Continuously evaluate the Lines that hit during the last 36 spins
(disregard the zero's)
Wait for the following pattern: 8 7 6 6 5 4
1 Line has hit 8 times
1 Line has hit 7 times
2 Lines have hit 6 times
1 Line has hit 5 times
1 Line has hit 4 times
(total: 36)
When that pattern appeared: bet the Line with 4 hits
for the next 6 non zero spins. Don't stop after a win.
Use a progression after a losing session.
-------------------------------------
}
method "main"
begin
while starting a new session
    begin
    call "init"
    exit
end

//do the tracking
track last number for 1 record"last N"layout
if record"last N"layout not = number 0 and record"last N"layout not = number 0
    begin
    set flag "0" false
    track last street for 36 record"last L"layout
    if record"last L"layout count < 36
        begin
        exit
        end
    call "update frequency"
    add 1 record"#spins"data
    end
    else
    begin
    set flag "0" true
    end

if record"#spins"data = 6 and flag "qualified" true
    begin
    call "reset"
    end

if net < 0 or net > 0
    begin
    call "update progression"
    end

if flag "qualified" false and flag "0" false
    begin

        call "sort frequencies"
        call "check the pattern"
        if record"C"data = 1
            begin
            group
                begin
                display "The hit frequency of Line1 to Line6 is:"
                put 1 record "go"data
                loop until record "go"data = 7
                    begin
                    put 100% record "go"data record"frequency2"data index
                    put 100% record"frequency2"data record"digits"data
                    call "display digits"
                    add 1 record "go"data
                    end
                if flag "qualified" true
                    begin
                    display "We have a QUALIFYING pattern"
                    end
                    else
                    begin
                    display "Pattern not qualifying"
                    end
                end
            end
        put 0 record"#spins"data

    end

if flag "qualified" true
    begin
    if record"P"data = 2
        begin put 1 record"pro"data end
    put 100% record"pro"data record"play"layout
    end

end

method "init"
begin
group
    begin
    display "DOUBLE TROUBLE"
    display "------------------------------------------------------------------"
    input dropdown "Progression:
    1:= On
    2:= Off" record"P"data
    input dropdown "Comments:
    1:= On
    2:= Off" record"C"data
    end
//Lines
copy list [Line(1-6),Line(7-12),Line(13-18),Line(19-24),Line(25-30),
Line(31-36)] record"lines"layout
copy list [Street(1-3),Street(7-9),Street(13-15),Street(19-21),Street(25-27),
Street(31-33)] record"lines1"layout
copy list [Street(4-6),Street(10-12),Street(16-18),Street(22-24),Street(28-30),
Street(34-36)] record"lines2"layout
put 100% bankroll record"high"data
put 100% bankroll record"previous"data
put 1 record"pro"data
call "reset"
end

method "reset"
begin
set flag "qualified" false
put 0 record"#spins"data
end

method "update frequency"
begin
clear record"frequency"data
set list [0,0,0,0,0,0] record"frequency"data
put 1 record"last L"layout index
loop until record"last L"layout index > record"last L"layout count
    begin
    put 1 record"lines1"layout index
    loop until record"lines1"layout index > record"lines1"layout count
        begin
        put 100% record"lines1"layout index record"lines2"layout index
        if record"lines1"layout = record"last L"layout or record"lines2"layout = record"last L"layout
            begin
            put 100% record"lines1"layout index record"frequency"data index
            add 1 record"frequency"data
            end
        add 1 record"lines1"layout index
        end
    add 1 record"last L"layout index
    end
end

method "sort frequencies"
begin
duplicate record"frequency" record"frequency2"
clear record"temp"data
put 1 record"run" data
loop until record"run" data = 7
    begin
    put 99 record"min"data
    put 1 record"frequency"data index
    loop until record"frequency"data index > record"frequency"data count
        begin
        if record"frequency"data < record"min"data and record"frequency"data > -1
            begin
            put 100% record"frequency"data record"min"data
            end
        add 1 record"frequency"data index
        end
    put 1 record"frequency"data index
    loop until record"frequency"data = record"min"data
        begin
        add 1 record"frequency"data index
        end
    put -1 record"frequency"data
    put 100% record"min"data record"temp"data
    add 1 record"temp"data index
    add 1 record"run" data
    end
duplicate record"frequency2" record"frequency"
end

method "check the pattern"
begin
put 1 record"temp"data index
if record"temp"data = 4
    begin
    put 2 record"temp"data index
    if record"temp"data = 5
        begin
        put 3 record"temp"data index
        if record"temp"data = 6
            begin
            put 4 record"temp"data index
            if record"temp"data = 6
                begin
                put 5 record"temp"data index
                if record"temp"data = 7
                    begin
                    put 6 record"temp"data index
                    if record"temp"data = 8
                        begin
                        set flag "qualified" true
                        put 1 record"frequency"data index
                        loop until record"frequency"data = 4
                            begin
                            add 1 record"frequency"data index
                            end
                        clear record"play"layout
                        put 100% record"frequency"data index record"lines"layout index
                        copy record"lines"layout record"play"layout
                        end
                    end
                end
            end
        end
    end
end

method "update progression"
begin
if bankroll > record"high"data
    begin
    put 100% bankroll record"high"data
    put 100% bankroll record"previous"data
    put 1 record"pro"data
    end
    else
    begin
    if bankroll > record"previous"data
        begin
        put 100% bankroll record"previous"data
        end
        else
        begin
        add 1 record"pro"data
        put 100% bankroll record"previous"data
        end
    end
end

method "display digits"
begin
if record"digits"data = 0 begin display "0" end
if record"digits"data = 1 begin display "1" end
if record"digits"data = 2 begin display "2" end
if record"digits"data = 3 begin display "3" end
if record"digits"data = 4 begin display "4" end
if record"digits"data = 5 begin display "5" end
if record"digits"data = 6 begin display "6" end
if record"digits"data = 7 begin display "7" end
if record"digits"data = 8 begin display "8" end
if record"digits"data = 9 begin display "9" end
if record"digits"data = 10 begin display "10" end
if record"digits"data = 11 begin display "11" end
if record"digits"data = 12 begin display "12" end
if record"digits"data = 13 begin display "13" end
if record"digits"data = 14 begin display "14" end
if record"digits"data = 15 begin display "15" end
if record"digits"data = 16 begin display "16" end
if record"digits"data = 17 begin display "17" end
if record"digits"data = 18 begin display "18" end
if record"digits"data = 19 begin display "19" end
if record"digits"data = 20 begin display "20" end
if record"digits"data = 21 begin display "21" end
if record"digits"data = 22 begin display "22" end
if record"digits"data = 23 begin display "23" end
if record"digits"data = 24 begin display "24" end
if record"digits"data = 25 begin display "25" end
if record"digits"data = 26 begin display "26" end
if record"digits"data = 27 begin display "27" end
if record"digits"data = 28 begin display "28" end
if record"digits"data = 29 begin display "29" end
if record"digits"data = 30 begin display "30" end
if record"digits"data = 31 begin display "31" end
if record"digits"data = 32 begin display "32" end
if record"digits"data = 33 begin display "33" end
if record"digits"data = 34 begin display "34" end
if record"digits"data = 35 begin display "35" end
if record"digits"data = 36 begin display "36" end
end
