sigonasr2, Sig, Sigo 3 years ago
parent 8b08f2a114
commit da689a2432
  1. 7
      combos3.js
  2. 1
      combos3.out
  3. 1
      combos3_2.out
  4. 1
      combos3_3.out
  5. 780
      combos3_4.out

@ -113,20 +113,23 @@ const FIRE=0;
driver4[0]=-1 driver4[0]=-1
//See if any elements match up. If they do, then add 1 to the max combo count. //See if any elements match up. If they do, then add 1 to the max combo count.
var matches=0; var matches=0;
var driver1performedon=0;
for (var ind=0;ind<3;ind++) { for (var ind=0;ind<3;ind++) {
if (driver1.length>0&&(combo[ind]==FIRE||combo[ind]==LIGHT)) { if (driver1.length>0&&(combo[ind]==FIRE||combo[ind]==LIGHT)) {
matches++; matches++;
driver1=[] driver1=[]
driver1performedon=ind
} else } else
if (driver1.includes(combo[ind])) { if (driver1.includes(combo[ind])) {
matches++; matches++;
driver1=[] driver1=[]
driver1performedon=ind
} else } else
if (driver4.length>0&&(combo[ind]==FIRE||combo[ind]==LIGHT)) { if (ind==2&&driver1performedon==0&&driver4.length>0&&(combo[ind]==FIRE||combo[ind]==LIGHT)) {
matches++; matches++;
driver4=[] driver4=[]
} else } else
if (driver4.includes(combo[ind])) { if (ind==2&&driver1performedon==0&&driver4.includes(combo[ind])) {
matches++; matches++;
driver4=[] driver4=[]
} else } else

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long
Loading…
Cancel
Save