Prechádzať zdrojové kódy

fix: franctions being rendered in incorrect order on end screen

lairaalmas 2 mesiacov pred
rodič
commit
bd4ddb1f8d
1 zmenil súbory, kde vykonal 10 pridanie a 0 odobranie
  1. 10 0
      js/games/squareTwo.js

+ 10 - 0
js/games/squareTwo.js

@@ -342,6 +342,16 @@ const squareTwo = {
         self.blocks.top.list.length,
         self.blocks.bottom.list.length,
       ];
+
+      if (gameMode === 'b') {
+        const leftNom = nominators[0];
+        const leftDenom = denominators[0];
+        nominators[0] = nominators[1];
+        denominators[0] = denominators[1];
+        nominators[1] = leftNom;
+        denominators[1] = leftDenom;
+      }
+
       const renderList = [];
 
       const padding = 100;