Update combos.js
Speed things up.
This commit is contained in:
parent
4e6065454d
commit
1bc2148e97
@ -102,6 +102,7 @@ const FIRE=0;
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
var combinations=0
|
var combinations=0
|
||||||
|
var triedcombos=0
|
||||||
for (var combo of combos) {
|
for (var combo of combos) {
|
||||||
var driver1=ConvertDriver(temp.substr(0,3))
|
var driver1=ConvertDriver(temp.substr(0,3))
|
||||||
var driver2=ConvertDriver(temp.substr(3,3))
|
var driver2=ConvertDriver(temp.substr(3,3))
|
||||||
@ -125,6 +126,10 @@ const FIRE=0;
|
|||||||
if (matches==3) {
|
if (matches==3) {
|
||||||
combinations++
|
combinations++
|
||||||
}
|
}
|
||||||
|
triedcombos++
|
||||||
|
if (combos.length-triedcombos+combinations<maxcombos) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (maxcombos<combinations) {
|
if (maxcombos<combinations) {
|
||||||
maxcombos=combinations
|
maxcombos=combinations
|
||||||
|
Loading…
x
Reference in New Issue
Block a user