Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- bdiv = 42000
- basebet = balance/bdiv
- nextbet = basebet
- multiplier = 1.5
- lodiv = 7000
- more = balance
- losebet = balance/lodiv
- target = balance*10
- chance = 50
- bethigh = false
- good = 0
- bad = 0
- bogus = 0
- betcount = 100 -- Number of Bets before Seed Reset
- counter = 0
- resetstats()
- lastWinRollCount = 0
- currentRollCount = 0
- oppositeRolls = 0
- oppositeArray = {}
- oppositeArrayCount = {}
- winCount = 0
- rollHighHigh = 0
- rollHighLow = 0
- rollLowHigh = 0
- rollLowLow = 0
- roundSpent = 0
- -- Initialize system settings
- rollCountAverage = {}
- rollAverageCount = 0
- rollAverageIndex = 0
- rollAverageMax = 8-- Average roll count before a win. How many wins do you want to average?
- -- Initialize the array
- for i=0, rollAverageMax do
- rollCountAverage[i] = 0
- end
- highLowAverage = {}
- averageCount = 0
- averageIndex = 0
- averageMax = 8-- High / Low average switching. How many rolls do you want to average?
- rollCount = 0
- rollSeedCount = 0
- -- Initialize the array
- for i=0, averageMax do
- highLowAverage[i] = 0
- end
- -- Start the actual betting
- function dobet()
- snow = balance/lodiv
- print("Current Balance : "..string.format("%.8f",balance))
- print("Current Profit : "..string.format("%.8f",profit))
- if balance-nextbet>=target then
- stop()
- ching()
- end
- if betcount == counter then
- resetseed();
- counter=0
- else
- counter+=1
- end
- if win then
- good += 1
- bogus += 1
- else
- bad+=1
- end
- if (bad == 1) then
- nextbet = balance/lodiv
- end
- if (bogus > 2) then
- nextbet = previousbet*multiplier
- bogus = 0
- end
- if (math.fmod(bad,4)==0) and (bad>3) then
- nextbet = previousbet*multiplier
- end
- if (good > 3) then
- nextbet = previousbet*multiplier
- good = 0
- end
- if (nextbet==nil) then
- nextbet = previousbet
- end
- if (balance > more+(snow*2)) then
- nextbet = balance/bdiv
- bad = 0
- good = 0
- bogus = 0
- more = balance
- end
- currentRollCount += 1
- rollCount += 1
- -- Store statistics for high / low rolls
- if(lastBet.roll > 50 and bethigh == true) then -- High roll and was high
- rollHighHigh += 1
- end
- if(lastBet.roll <= 50 and bethigh == true) then -- High roll and was low
- rollHighLow += 1
- end
- if(lastBet.roll > 50 and bethigh == false) then -- Low roll and was high
- rollLowHigh += 1
- end
- if(lastBet.roll <= 50 and bethigh == false) then -- Low roll and was low
- rollLowLow += 1
- end
- -- We got a win, let's store some averages
- if(win) then
- winCount += 1
- if(rollAverageCount == 0) then -- Initialize so we get a good starting average
- for i=0, rollAverageMax do
- rollCountAverage[i] = rollCount
- end
- rollAverageIndex += 1
- else
- rollCountAverage[rollAverageIndex] = rollCount
- rollAverageIndex += 1
- end
- rollAverageCount += 1
- if(rollAverageCount >= rollAverageMax) then
- rollAverageCount = rollAverageMax -- no need to keep this one climbing
- end
- if(rollAverageIndex >= rollAverageMax) then
- rollAverageIndex = 0 -- reset
- end
- rollCount = 0 -- reset for next rolling
- oppositeRolls = 0
- rollSeedCount = 0 -- Keep this seed for now
- rollHighHigh = 0 -- reset counters
- rollHighLow = 0 -- reset counters
- rollLowHigh = 0 -- reset counters
- rollLowLow = 0 -- reset counters
- roundSpent = 0
- end
- -- Let's use the averages from previous rolls to see if the bet needs to be changed
- if(!win) then
- oppositeTest = lastBet.roll
- end
- if(oppositeTest > (100 - chance) and bethigh == false) then -- Test if we were rolling high
- -- print(oppositeTest)
- oppositeArray[oppositeRolls] = oppositeTest
- oppositeArrayCount[oppositeRolls] = rollCount
- oppositeRolls += 1
- end
- if(oppositeTest < chance and bethigh == true) then -- Test if we were rolling low
- -- print(oppositeTest)
- oppositeArray[oppositeRolls] = oppositeTest
- oppositeArrayCount[oppositeRolls] = rollCount
- oppositeRolls += 1
- end
- -- Calculate the average, and then change high / low accordingly
- if(lastBet.roll >= 50) then
- highLowAverage[averageIndex] = 1
- else
- highLowAverage[averageIndex] = 0
- end
- averageIndex += 1
- averageCount += 1
- if(averageIndex >= averageMax) then
- averageIndex = 0
- end
- if(averageCount > averageMax) then
- averageCount = averageMax
- end
- average = 0.00
- for i=0, averageCount do
- average += highLowAverage[i]
- end
- average = average / averageCount
- -- print (average)
- if (average >= 0.5) then
- bethigh = true
- else
- bethigh = false
- end
- end
Add Comment
Please, Sign In to add comment