diff --git a/KfChatDotNetBot/Commands/KasinoGambaCommands.cs b/KfChatDotNetBot/Commands/KasinoGambaCommands.cs index 4bf5f6a..38b9ea5 100644 --- a/KfChatDotNetBot/Commands/KasinoGambaCommands.cs +++ b/KfChatDotNetBot/Commands/KasinoGambaCommands.cs @@ -381,22 +381,21 @@ public class Planes : ICommand if (fullCounter < 20 || (fullCounter-3) % 20 > 3) useBoard = 0; else if (fullCounter >= 20 && (fullCounter - 3) % 20 < 3) useBoard = 1; else logger.Info($"Failed to select proper gameboard for gameplay outcome. UseBoard: {useBoard} | FullCounter: {fullCounter} | Counter: {counter} | Height: {plane.Height} | FrameCounter: {frameCounter}"); - switch (planesBoards[boardCounter % 2][plane.Height, counter]) { - + case 0: //do nothing plane hit neutral space neutral = true; if (fullCounter == 3) logger.Info($"Generated first plane impact outcome. Framecounter: {frameCounter} | FullCounter: {fullCounter} | Counter: {counter} | Outcome: neutral"); break; case 1: //hit rocket - planesBoards[boardCounter % 2][plane.Height, counter] = 0; //plane consumes rocket + planesBoards[useBoard][plane.Height, counter] = 0; //plane consumes rocket plane.HitRocket(); noseUp = false; if (fullCounter == 3) logger.Info($"Generated first plane impact outcome. Framecounter: {frameCounter} | FullCounter: {fullCounter} | Counter: {counter} | Outcome: bomb"); break; case 2: //hit multi - planesBoards[boardCounter % 2][plane.Height, counter] = 0; //plane consumes multi + planesBoards[useBoard][plane.Height, counter] = 0; //plane consumes multi plane.HitMulti(); noseUp = true; if (fullCounter == 3) logger.Info($"Generated first plane impact outcome. Framecounter: {frameCounter} | FullCounter: {fullCounter} | Counter: {counter} | Outcome: multi"); @@ -434,11 +433,10 @@ public class Planes : ICommand { break; } - //maybe fuckery around here + //maybe fuckery around here } fullCounter++; } - plane.Gravity(); if ((fullCounter-3) % 20 == 3 && !firstBoard)//removes old planesboard, adds new planeboard when necessary **********************************************************************NEEDS MORE UPDATES { @@ -569,14 +567,16 @@ public class Planes : ICommand if ((firstBoard && (counter + column < 20)) || (!firstBoard && (counter + column < 0))) useBoard = 0; else if ((firstBoard && (counter + column > 19)) || (!firstBoard && (column + counter < 20))) useBoard = 1; - else if (!firstBoard && (counter + column > 20)) useBoard = 2; + else if (!firstBoard && (counter + column > 19)) useBoard = 2; else { logger.Info($"Failed to properly switch to the correct board. Fullcounter: {fullCounter} | Counter: {counter} | Row: {row} | Column: {column} | FirstBoard: {firstBoard} "); useBoard = -1; } - - + if (column + counter > 19) + { + counter = (fullCounter - 3) % 20; + } if (row == plane.Height && column == -1 && plane.JustHitMulti > 1) { output += Boost; @@ -595,7 +595,6 @@ public class Planes : ICommand break; } } - else if (row == 6)//row between the gameboard and where the carrier is displayed, should show the plane in this row on top of the boat on a win { output += Air; @@ -613,7 +612,6 @@ public class Planes : ICommand * instead it needs to use that counter to iterate back * so in this case where the value is -3, we need planesBoards[0][row, 20 - counter] */ - if (firstBoard && (counter + column < 0)) { output += Air; @@ -637,7 +635,6 @@ public class Planes : ICommand } } output += "[br]"; - } return output; @@ -665,7 +662,6 @@ public class Planes : ICommand } } } - return board; } }